function ajax_error_behavior_init in AJAX Error Behavior 7
Implements hook_init().
File
- ./
ajax_error_behavior.module, line 37 - Code to provide configuration for different ajax error behaviors.
Code
function ajax_error_behavior_init() {
$settings = array(
'behavior' => variable_get('ajax_error_behavior', 'core'),
'error' => variable_get('ajax_error_behavior_error', t('There was some error in the user interface, please contact the site administrator.')),
'watchdog_url' => url('ajax_error_behavior/watchdog', array(
'absolute' => TRUE,
)),
);
drupal_add_js(array(
'ajaxErrorBehavior' => $settings,
), 'setting');
}