You are here

function styleswitcher_preprocess_page in Style Switcher 6

Same name and namespace in other branches
  1. 6.2 styleswitcher.module \styleswitcher_preprocess_page()

Implementation of hook_preprocess_page(). Add styles and scripts in the specific way necessary for this to work.

File

./styleswitcher.module, line 70
Framework for themes to easily add stylesheet switching functionality.

Code

function styleswitcher_preprocess_page(&$variables) {

  // add the alternate stylesheets
  $variables['styles'] .= join("\n", _styleswitcher_add_css());

  // append to scripts since this needs to run after the drupal settings object.
  $variables['scripts'] .= drupal_get_js('styleswitcher');
}