Page 1 of 1

Showing a gallery in the output of a custom module

Posted: Wed May 16, 2012 12:46 pm
by Raffael
Hello,

first of all, thanks for making such an amazing gallery software and even for free :) I'm already using it within articles and it works like a charm. However, recently I tried to display a gallery within the html output that is generated by a custom module I wrote, and in this case the {ag} and {/ag} tags aren't parsed - is it possible to trigger the parsing of the code by Admiror Gallery somehow by adding some code to my custom module?

Any help would be greatly appreciated!

Re: Showing a gallery in the output of a custom module

Posted: Tue May 22, 2012 10:51 am
by Vasiljevski
Yes, you should check this great article that explains the idea of how to do it: http://ostraining.com/howtojoomla/how-t ... nt-plugins

But if you want to go straight to coding, add with something like this to your module:

Code: Select all

JPluginHelper::importPlugin( 'content','AdmirorGallery' );
$dispatcher =& JDispatcher::getInstance();
$dispatcher->trigger('onPrepareContent', array ( &$article, & $params, $limitstart));