You are here

function janrain_capture_fancybox_init in Janrain Registration 7.4

Same name and namespace in other branches
  1. 7.2 includes/janrain_capture.fancybox.inc \janrain_capture_fancybox_init()
  2. 7.3 includes/janrain_capture.fancybox.inc \janrain_capture_fancybox_init()

Fancybox initialisation function

1 call to janrain_capture_fancybox_init()
janrain_capture_page_build in ./janrain_capture.module
Implements hook_page_build().

File

includes/janrain_capture.fancybox.inc, line 10
Fancybox functions

Code

function janrain_capture_fancybox_init() {
  $js_css = janrain_capture_js_css();
  foreach ($js_css as $type => $files) {
    foreach ($files as $name => $filename) {

      // Find the location of the library file and add it using the appropriate
      // function, i.e. drupal_add_js or drupal_add_css.
      $full_path = janrain_capture_get_library_path($name) . '/' . $filename;
      $drupal_add = 'drupal_add_' . $type;
      $drupal_add($full_path, array(
        'every_page' => TRUE,
      ));
    }
  }
}