You are here

function slickgrid_menu_alter in Slickgrid 6

Implementation of hook_menu_alter().

File

./slickgrid.module, line 61

Code

function slickgrid_menu_alter(&$items) {

  // JSON parsing is much stricter is jquery 1.4 so using drupal_to_js() in AHAH callbacks will result in a parse error
  // Rewrite the callbacks to use json_encode()
  // Content add more
  $items['content/js_add_more']['page callback'] = 'slickgrid_content_add_more_js';
  $items['content/js_add_more']['file'] = 'slickgrid.ahah.inc';
  $items['content/js_add_more']['file path'] = drupal_get_path('module', 'slickgrid');

  // File field
  $items['filefield/ahah/%/%/%']['page callback'] = 'slickgrid_filefield_js';
  $items['filefield/ahah/%/%/%']['file'] = 'slickgrid.ahah.inc';
  $items['filefield/ahah/%/%/%']['file path'] = drupal_get_path('module', 'slickgrid');

  // Node reference autocomplete
  $items['nodereference/autocomplete']['page callback'] = 'slickgrid_nodereference_autocomplete';
  $items['nodereference/autocomplete']['file'] = 'slickgrid.ahah.inc';
  $items['nodereference/autocomplete']['file path'] = drupal_get_path('module', 'slickgrid');
}