(Joomla 3.x) Get menu, template, plugin, module & component parameters

Select your language

 

Get module parameters from template's index.php file:

$module = JModuleHelper::getModule('mod_headlineticker');
$headLineParams = new JRegistry($module->params);
$tickercount = (int) $headLineParams['count'];
 
 

To access component params in component itself, I use JFactory::getApplication() like below:

$app = JFactory::getApplication();
$params = $app->getParams();
$param = $params->get('show_create_date');

To access component parameters from another component:

$content_params = JComponentHelper::getParams( 'com_content' );
$show_date = $content_params->get( 'show_create_date' );

Or even shortcut:

$show_date = JComponentHelper::getParams('com_content')->get('show_create_date');

 Hope this helped.


Still need help! no problem, feel free to contact us Today


 Abdul Waheed : (Hire Joomla & PHP Pakistani Freelancer)