tebdilikiyafet Posted February 19, 2013 Share Posted February 19, 2013 Hi everybody; I don't know if it is possible but I want to ask. for example: I use blockmyaccountfooter module in footer. I also want to use it in "top" with different design. I added this hook to module php folder and transplant the module to the "top". We know that module has a .tpl file and I want to divide it two part. First part will used by hookfooter second part will used by hooktop like below: ----blockmyaccountfooter.tpl---- {if $HOOK_FOOTER} //some tpl codes {/if} {if $HOOK_TOP} //some tpl codes {/if} Can I do this? Link to comment Share on other sites More sharing options...
croqueurdos Posted May 3, 2013 Share Posted May 3, 2013 :up: Hi all I need exactly the same thing ! Any idea ? Thanks ! Fred (sorry for my poor english, i'm not one, so I hope you understand me !). Link to comment Share on other sites More sharing options...
croqueurdos Posted May 4, 2013 Share Posted May 4, 2013 Hi all again It's ok, I have the solution, and it is...easy. You need to change in your PHP file (the PHP file in the module directory, of course). The change to do is to add a new block of lines with the hook you need to see your module. For exemple, in my case, I want to have the module Newsletter on the left colomn AND the footer. So, in the PHP file, I added this block : public function hookFooter($params) { $this->_prepareHook($params); return $this->display(__FILE__, 'blocknewsletter_footer.tpl'); } So the module newsletter can be attached to this hook (footer) and you can see I changed the TPL file with a new one (duplicate the initial one, and then you can change all you want, class, div,...). I hope I am enough clear in my explain ? ++ Fred 1 Link to comment Share on other sites More sharing options...
vekia Posted May 4, 2013 Share Posted May 4, 2013 @croqueurdos has got right in this case. This is basics in module development. I can go ahead and mark this thread as solved. If you've got any other quesitons related to this case - feel free to write here Link to comment Share on other sites More sharing options...
Recommended Posts