Skip to content

Instantly share code, notes, and snippets.

@indikatordesign
Last active May 11, 2018 19:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save indikatordesign/cb26190342bb9fdfe6610d32177ef416 to your computer and use it in GitHub Desktop.
Save indikatordesign/cb26190342bb9fdfe6610d32177ef416 to your computer and use it in GitHub Desktop.
[Bloom - GDPR - Text override settings]
<?php
// If you want to change your texts for the overlay on certain pages, then open the "functions.php"
// of your theme and use the following snippet. Customize the text to your needs.
// This function is possible since version 1.0.5
add_filter( 'bgop_overlay_messages', function( $messages )
{
if ( is_page( [ 'my-awesome-page', 'New Infos for your Health', 1234 ] ) ) // add pages by slug, title, id
{
$company = 'Company Name';
$messages['linkBefore'] = 'This form stores the data entered as explained in our'; // text before the link
$messages['linkName'] = 'Our Privacy Policy'; // the link name
$messages['linkHref'] = 'https://example.com/privacy/'; // the link itself
$messages['linkAfter'] = 'You can revoke at any time.'; // text after the link
$messages['company'] = $company;
$messages['agree'] = "I hereby agree to my data being stored by {$company}."; // Agreement next to the checkbox
} // end if
return $messages;
}); // end add_filter
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment