If you use the enfold GDPR privacy function the resulting cookie message seems to appear in the google snippets and search results.
Currently, there seems to be no setting or filter to modify that.
The code is located here:
/wp-content/themes/enfold/includes/helper-privacy.php
line 1614:
handler_wp_footer_cookie_consent_bar
line 1946:
$output = '<div class="avia-cookie-consent-wrap" aria-hidden="true">' . $output . '</div>';
This div-Tag class will be find with language specific text in your website.
I got a bit research how to solve the problem – i think the best way will be to:
– insert a switch to hide the code from snippet
– or to hide the privacy-message completely from search engine results
Google may use:
– to hide from snippet:
<div data-nosnippet>
not in snippet
</div>
Source: https://developers.google.com/search/docs/advanced/robots/robots_meta_tag
– to hide from google results:
<p>
Do index this text.
<!--googleoff: all-->
Don't index this text.
<!--googleon: all-->
</p>
Source: https://en.wikipedia.org/wiki/Noindex
I there is no other way, may you like to integrate such a function?
Thank you!
Hey kisys,
Thank you for the info.
The attribute was already added in the latest version (4.8.7.1) of the theme including a new filter (https://kriesi.at/support/topic/prevent-consent-manager-from-being-indexed-by-google/#post-1323153) that should allow you to adjust it. Please check the following thread for more info.
// https://kriesi.at/support/topic/prevent-consent-manager-from-being-indexed-by-google/#post-13231533
Best regards,
Ismael