Search code examples
joomla2.5joomla-template

How to get component name?


How to get component name in Joomla 2.5 template?

ie: com_contact, com_search, com_kunena?

I want to insert

<jdoc:include type="modules" name="right"/> 

only on kunena forum... How to do it?


Solution

  • try this,

    <?php if(JRequest::getVar('option') == 'com_kunena'): ?>
    <jdoc:include type="modules" name="right"/> 
    <?php endif ?>
    

    Instead of this just assign the module to the proper menu from the module manager then it will be available only on that pages.

    Hope its helps..