【发布时间】:2014-04-07 05:54:31
【问题描述】:
你好!
我想检查实际页面是否在菜单中。 我想做drupal模板(page.tpl.php)。 例如:
if ($page_is_a_menuitem):
echo "This page is in the menu";
else:
echo "This page not in the menu";
endif;
因为如果页面在菜单中a想要突出显示标题。
对不起,我的英语不好。
【问题讨论】:
-
我认为您不需要手动执行此操作,因为如果您在页面上,Drupal 会在菜单项上为您提供“活动”类。
-
尝试新代码。我希望旧代码更好并且有用
标签: php templates drupal menu drupal-7