You are here

function pagestyle_jq_plugin in Page Style 6

Note: By default the "jQuery plugins" module is required. You can also download the plugin from http://plugins.jquery.com/project/Cookie in the modul pagestyle, uncomment the code below and delete the code:

Delete the line: jquery_plugin_add('cookie');

Uncomment example: drupal_add_js(drupal_get_path('module', 'pagestyle') .'/jquery.cookie.js');

1 call to pagestyle_jq_plugin()
pagestyle_init in ./pagestyle.module
Implement hook_init().

File

./pagestyle.module, line 370
Display a style changer on the page and in the browser menu for a better web accessibility.

Code

function pagestyle_jq_plugin() {
  $link_jquery_plugin = l(t('jQuery plugins'), 'http://drupal.org/project/jquery_plugin');
  if (function_exists('jquery_plugin_add')) {
    jquery_plugin_add('cookie');
  }
  else {
    drupal_set_message(t('Drupal\'s %link_jquery_plugin Module Required for Page Style functionality.', array(
      '!link_jquery_plugin' => $link_jquery_plugin,
    )), 'error');
  }
}