function fb_devel_translated_menu_link_alter in Drupal for Facebook 6.3
Same name and namespace in other branches
- 7.4 fb_devel.module \fb_devel_translated_menu_link_alter()
- 7.3 fb_devel.module \fb_devel_translated_menu_link_alter()
File
- ./
fb_devel.module, line 57 - Makes development with Drupal for Facebook much easier. Keep this module enabled until you're confident your app works perfectly.
Code
function fb_devel_translated_menu_link_alter(&$item) {
if ($item['link_path'] == 'fb/devel/linter' || $item['link_path'] == FB_DEVEL_URL_LINTER) {
//dpm($item, __FUNCTION__);
$item['href'] = FB_DEVEL_URL_LINTER;
// href matters. link_path and router path do not.
$item['localized_options']['query'] = array(
'url' => url($_GET['q'], array(
'absolute' => TRUE,
)),
);
}
}