Prestashop - override function in existing prestashop module

I use my own override to the FrontController class to allow the display of module output at arbitrary points in tpl files - this means that the module doesn't need to support a particular hook. It is implemented via a smarty plugin, so you can for example use:

{plugin module='blockcart' hook='rightColumn'}

The above will force the module to output what it would display if hooked to the right column where the above is tag inserted (which can be anywhere in any tpl file). You can "unhook" the module from the right column so that it only displays where you want it to using this technique. I have used it on a production site with great success.

There's a series of articles describing how it works (with the required code) available at:

Prestashop 1.4 Plugins


In Prestashop 1.4 you can override core classes and module templates Today this is not possible to override a module php file but we are working on it.

Tags:

Prestashop