Jump to content

[SOLVED] How to have 2 of the same module??


Recommended Posts

Hi all, thanks to all that read this and help out, and thanks to those who make prestashop!

I'm starting a new shop and for my purposes I really need to be able to have different lists of pages, in different blocks, on my menu. In other words I want more than one (maybe two or three) of the 'link block' - is this possible?

Thanks

http://www.psychicreadingbyphone.co.uk/

Link to comment
Share on other sites

Basically, you just need to copy the blocklink module and rename every instance of "blocklink" to "blocklink2". For example, copy the blocklink module directory to blocklink2, then rename blocklink.php to blocklink2.php, then edit blocklink2.php and change the class name from BlockLink to BlockLink2 and $this->name('blocklink'); to $this->name('blocklink2');, and the database table from 'blocklink' to 'blocklink2' and the variable like 'PS_BLOCKLINK_TITLE' to 'PS_BLOCKLINK2_TITLE'. If you change everything correctly, you should be have the module appear twice on your Modules tab and you should be able to configure them with different links.

Link to comment
Share on other sites

  • 3 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...