From 913d538871bd43d040b98a2fe529ca6c8f1a78f3 Mon Sep 17 00:00:00 2001 From: Dries Buytaert <dries@buytaert.net> Date: Wed, 6 Feb 2008 19:41:24 +0000 Subject: [PATCH] - Patch #218319 by Moshe: added support for dynamic menu items in query strings. --- includes/menu.inc | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/includes/menu.inc b/includes/menu.inc index e8d67b2878bd..1e8817ac6bbd 100644 --- a/includes/menu.inc +++ b/includes/menu.inc @@ -652,6 +652,14 @@ function _menu_link_translate(&$item) { _menu_item_localize($item, $map, TRUE); } + + // Allow other customizations - e.g. adding a page-specific query string to the + // options array. For performance reasons we only invoke this hook if the link + // has the 'alter' flag set in the options array. + if (!empty($item['options']['alter'])) { + drupal_alter('translated_menu_link', $item, $map); + } + return $map; } -- GitLab