cedib Posted September 30, 2019 Share Posted September 30, 2019 Hi, Would it be right to think that some modules hooked to hookdisplayHeader can add to the loading time of a page for no reason other than the fact that they are hooked on it, such as Paypal, productcomments, mailalert, rewards and giftcards? Those modules are actually needed only to specific pages, such as product pages or cart, but not the home page, cms pages or categories. Therefore has anyone ever considered adding some exceptions in the Modules Positions page so those modules are not called in some particular pages? I'm thinking about doing it to optimise the load and speed of pages. Good idea or risk to break something? Thanks Link to comment Share on other sites More sharing options...
razaro Posted October 2, 2019 Share Posted October 2, 2019 Hi There is bit older article with one point just about your question http://build.prestashop.com/howtos/module/Common-mistakes-while-coding-module/#5-do-not-trigger-code-if-it-is-for-a-specific-page So yes it is good practice. Link to comment Share on other sites More sharing options...
cedib Posted October 2, 2019 Author Share Posted October 2, 2019 Awesome thanks @razaro! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now