SOAMJENA Posted July 8, 2014 Share Posted July 8, 2014 Dear sir, I want to activate a custom module only on a single category page (Which is also displayed on menu item on frontend).This module must be activated only on that category page not on other pages.. But I can't able to do that.. Please advice.. Link to comment Share on other sites More sharing options...
vekia Posted July 8, 2014 Share Posted July 8, 2014 prestashop hasn't got feature to display contents only on selected category pages. it means that it's necessary to create code to support it. in this case, the simplest solution will be condition in php file, in hook: public displayYourHook($params){ if (isset($_GET['id_cat']){ if ($_GET['id_cat']==5){ // contents here } } } Link to comment Share on other sites More sharing options...
SOAMJENA Posted July 8, 2014 Author Share Posted July 8, 2014 Ok i got it for category page. Now I have a Custom CMS page on my Prestashop store and I want to activate the module only on that custom page. Please provide the condition code for php file to achieve above. Link to comment Share on other sites More sharing options...
vekia Posted July 8, 2014 Share Posted July 8, 2014 the same code as above, just instead id_cat use id_cms Link to comment Share on other sites More sharing options...
SOAMJENA Posted July 8, 2014 Author Share Posted July 8, 2014 It works.. Thanks... Link to comment Share on other sites More sharing options...
Recommended Posts