Tag: template

  • Tired of hooks? Try a Plugin (Prestashop 1.4)

    Please note that this version only works currently for Smarty v2, enabling smarty v3 will cause an error. I’ll post an update that resolves this issue shortly.

    Update: This article has been revised in: 1.4 Plugins Revisited

    In a previous article Display Module Output Anywhere I touched on the subject of subverting Prestashop’s internal Module architecture to our own ends. In this article we’ll be looking at creating a new mechanism for injecting module output into themes that doesn’t rely on tedious code changes, and should be able to be employed by (almost) anyone regardless of programming ability.

    How about being able to display the home featured products anywhere in your template files just by adding a single line (as below)?

    {plugin module='homefeatured' hook='home'}

    If this looks like something you would find useful, then read on….

    (more…)
  • Customising Prestashop Module Templates

    Please don’t edit those originals!

    I came across this little gem a while ago on the Prestashop forum, and thought I would draw attention to it in the hopes that it will help someone, somewhere.

    (more…)
  • Randomly Displayed Adverts and Callouts

    Another useful tool for conversions is being able to attract the attention of your visitors and guide them to the parts of your site you really want them to see. We’ve come up with yet another great little PrestaShop module to do precisely that!

    (more…)
  • Preventing the copying of your site design templates

    I was browsing the prestashop forum and ended up on a thread concerning an issue with people stealing a site design by downloading the template files from the theme directory. It struck me that this is probably something that those of you who use other template systems with your sites may also face, so thought I’d post the solution here too.

    The problem is that although php files cannot be viewed directly on your browser, other source files can be e.g. files ending in .tpl

    The best way to protect your site is to change the permissions on these files to 600. This will make them accessible only by your own code on the server and present anyone nosey enough to try and look at them with a 403 (forbidden) error. The same is true for php files (although these shouldn’t display the source unless your server configuration is broken).

    Simple.