3

If I create a page (like a view in Drupal) I can add a link to it in Civi's Navigation Menu. But then you go to that page and the Navigation Menu disappears. The path for that page is /civicrm/something-custom but apparently starting with civicrm/* doesn't automagically display the menu. How can I make the menu appear on custom pages?

A method via code (hook_something would be better than hack_something) would be sufficient, as I don't see any options in the UI at civicrm/admin/menu.

The docs list a hook_civicrm_navigationMenu but it sounds like it only alters the menu itself, as opposed to allowing me to display it when it's not otherwise displayed.

I did a grep through the codebase for civicrm-menu and sites/all/modules/civicrm/templates/CRM/common/navigation.js.tpl looked the most promosing but wasn't enlightening itself, then I saw that sites/all/modules/civicrm/CRM/Admin/Page/AJAX.php prints that file inside of a public static function getNavigationMenu() and there's a comment for that function @see smarty_function_crmNavigationMenu. But searching the web doesn't yield any results on invoking these functions in custom code.

Surely this has been done before... right? Is there a proper method for doing so?

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.