You are here

function theme_eu_cookie_compliance_popup_agreed in EU Cookie Compliance (GDPR Compliance) 5

This is a template fucntion for a pop-up informing a user that he has already agreed to cookies.

When overriding this template it is important to note that jQuery will use the following classes to assign actions to buttons:

hide-popup-button - destroy the pop-up find-more-button - link to an information page

Variables available:

  • $message: Contains the text that will be display whithin the pop-up
  • $link: Contains a link to an information page (not used in the original template as JQuery redirects to the information page on clinking the find-more button. $link is available though in case you want to overrride the template and display the link another way.
1 theme call to theme_eu_cookie_compliance_popup_agreed()
eu_cookie_compliance_footer in ./eu_cookie_compliance.module
Implements hook_footer().

File

./eu_cookie_compliance.module, line 252
This module intends to deal with the EU Directive on Privacy and Electronic Communications that comes into effect in the UK on 26th May 2012.

Code

function theme_eu_cookie_compliance_popup_agreed($message = NULL, $link = NULL) {
  $hide_msg = t("Hide this message");
  $find_more = t("More information on cookies");
  return <<<POPUP
\t\t<div>
\t\t\t<div class ="popup-content agreed">
\t\t\t\t<div id="popup-text">
\t\t\t\t\t{<span class="php-variable">$message</span>}
\t\t\t\t</div>
\t\t\t\t<div id="popup-buttons">
\t\t\t\t\t<button type="button" class="hide-popup-button">{<span class="php-variable">$hide_msg</span>}</button>
\t\t\t\t\t<button type="button" class="find-more-button" >{<span class="php-variable">$find_more</span>}</button>
\t\t\t\t</div>
\t\t\t</div>
\t\t</div>
POPUP;
}