BellaHarry Posted September 1, 2017 Share Posted September 1, 2017 Hi, this is my first time here. I am using PrestaShop 1.6 and am a complete novice. I would like to add text to my category pages at the bottom after the products and before footer. I don't know how to use hooks, I am totally confused. Could someone please help? I didn't think it would be so hard to add text to any page other than the home page. Thank you. Link to comment Share on other sites More sharing options...
NemoPS Posted September 1, 2017 Share Posted September 1, 2017 Are you willing to add some generic text, identical for all categories, or specifically for each?The latter would require you to edit php files as well, or creating a module Link to comment Share on other sites More sharing options...
Ava123 Posted September 1, 2017 Share Posted September 1, 2017 Yes, specifically for each. Are you able to give me an example that I could adapt to my requirements? Link to comment Share on other sites More sharing options...
BellaHarry Posted September 1, 2017 Author Share Posted September 1, 2017 Thank you, I would like to add different text to the bottom of my pages as well. Are there any tutorials to show us how to edit the php files so we can do this? Link to comment Share on other sites More sharing options...
NemoPS Posted September 2, 2017 Share Posted September 2, 2017 It's explained in my modules course actually, virtually impossible to describe step by step here in the forum.Basically create a module that creates a new hook, have it hook to the category back office as well. It also needs to whether extend the category class or create a new table to hold the settingThen it would add a box in the category config page through that hook, where you could save the text for each category.The last step would be adding the hook variable to category.tpl (theme folder) to display stuff.The module obviously needs to output through it 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