Joomla Module with Multiple Occurrence In Article Layout.

For Joomla! 3.x Coding related discussions, you could also use: http://groups.google.com/group/joomla-dev-general

Moderators: ooffick, General Support Moderators

Forum rules
Locked
phpgeek
Joomla! Apprentice
Joomla! Apprentice
Posts: 9
Joined: Wed Oct 08, 2014 7:52 am

Joomla Module with Multiple Occurrence In Article Layout.

Post by phpgeek » Sat Oct 11, 2014 6:21 pm

Hi Guys, I am new to joomla development, i have created a module of registration in which the fields will be dynamically set if we want to show or not, like this module contain a form with multiple inputs, and i will use this form on homepage, on registration page and on contact us page, on every occurrence i need to show different fields, in registration page and in contact us page, i can use {loadposition } in articles directly but for homepage, i am using alternative layout, in which i have to show this module, if i use code below this won't work for me and i am unable to understand if i can use getmodules from positions and then load it,

Code: Select all

   $module = JModuleHelper::getModule('mod_registrationform');
$registrationform = JModuleHelper::renderModule($module);
            echo $registrationform;
Please help me i have spent 2 days on searching this solution. and i haven't found solution.

Regards,

Nils
Joomla! Apprentice
Joomla! Apprentice
Posts: 7
Joined: Sun Sep 10, 2006 8:05 pm

Re: Joomla Module with Multiple Occurrence In Article Layout

Post by Nils » Thu Oct 16, 2014 1:56 pm

Where are you using the code?

Have you considered using a module position in your template instead?


Locked

Return to “Joomla! 3.x Coding”