ZaxxaDK Posted August 15, 2016 Share Posted August 15, 2016 Im trying to figure out how exactly the hooks work in prestashop, and i seem not to be able to find any good documentation with exampels. If fx. i want to use the displayCarrierList hook, to see the carrier list - how does one do that? Link to comment Share on other sites More sharing options...
vekia Posted August 15, 2016 Share Posted August 15, 2016 Hooks are a way to associate your code to some specific PrestaShop events. Most of the time, they are used to insert content in a page. For instance, the PrestaShop default theme's home page has the following hooks: displayTop - Displays the content in the page's top area. displayRightColumn - Displays the content in the page's right column. displayLeftColumn - Displays the content in the page's left column. displayHome - Displays the content in the page's central area. displayHeader - Displays the content in the page's header area. displayFooter - Displays the content in the page's footer area. Prestashop has many hooks. Each of them appears in other places. Some of them appears globally (header,top,footer etc.) some of them only on selected parts of shop like order process, order confirmation etc. hook that you mentioned: displayCarrierList is spawned during order process. it appears there, where the list of carries appears during checkout. Link to comment Share on other sites More sharing options...
ZaxxaDK Posted August 16, 2016 Author Share Posted August 16, 2016 Hooks are a way to associate your code to some specific PrestaShop events. Most of the time, they are used to insert content in a page. For instance, the PrestaShop default theme's home page has the following hooks: displayTop - Displays the content in the page's top area. displayRightColumn - Displays the content in the page's right column. displayLeftColumn - Displays the content in the page's left column. displayHome - Displays the content in the page's central area. displayHeader - Displays the content in the page's header area. displayFooter - Displays the content in the page's footer area. Prestashop has many hooks. Each of them appears in other places. Some of them appears globally (header,top,footer etc.) some of them only on selected parts of shop like order process, order confirmation etc. hook that you mentioned: displayCarrierList is spawned during order process. it appears there, where the list of carries appears during checkout. So the displayCarrierList cant show me my custom carriers or am i retarded ? 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