You are here

function dynamicload_load in Javascript Tools 5

Load needed files.

1 call to dynamicload_load()
dynamicload_menu in dynamicload/dynamicload.module
Implementation of hook_menu().

File

dynamicload/dynamicload.module, line 144
Enable AJAX-based loading of selected page elements.

Code

function dynamicload_load() {
  static $loaded = FALSE;
  if (!$loaded) {
    jstools_modules_includes('dynamicload');
    $path = drupal_get_path('module', 'dynamicload');
    jstools_add_js(array(
      $path . '/dynamicload.js',
      'misc/progress.js',
    ));
    drupal_add_js(drupal_get_path('module', 'jstools') . '/jquery.history_remote.pack.js');

    // Insert dummy content that will be used to select the region container.
    // We need to manually set the left and right
    _dynamicload_set_region_markers(array(
      'left',
      'right',
    ));
    drupal_add_css(drupal_get_path('module', 'block') . '/block.css');
    $loaded = TRUE;
  }
}