Question

I want to get parameters of a specific menu in joomla3/k2

I can get current menu by this code:

$params = K2HelperUtilities::getParams('com_k2');

$_myparam=$params->get('menu-meta_url');

Now how can I call $params->get('menu-meta_url') form another page or module?!

Was it helpful?

Solution

Well - if you just want to get the current menu params... you can use the default.

  $itemid = JRequest::getVar('Itemid');
  $menu = &JSite::getMenu();
  $active = $menu->getItem($itemid);
  $params = $menu->getParams( $active->id );
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top