function ajax_links_api_init in Ajaxify Drupal with JQuery Ajax 6
Same name and namespace in other branches
- 7 ajax_links_api.module \ajax_links_api_init()
Implements hook_init().
File
- ./
ajax_links_api.module, line 12 - Make any links or create new links to load content to particular DIV via jQuery Ajax.
Code
function ajax_links_api_init() {
drupal_add_js(drupal_get_path('module', 'ajax_links_api') . '/ajax_links_api.js');
drupal_add_css(drupal_get_path('module', 'ajax_links_api') . '/ajax_links_api.css');
$selector = variable_get('ajax_links_api_selector', '#content');
$trigger = ajax_links_api_get_triggers();
$html5 = variable_get('ajax_links_api_html5', 1);
$views_pager = variable_get('ajax_links_api_vpager', 1);
drupal_add_js(array(
'ajax_links_api' => array(
'selector' => $selector,
'trigger' => $trigger,
'html5' => $html5,
'vpager' => $views_pager,
),
), 'setting');
}