krisives Posted January 3, 2014 Share Posted January 3, 2014 Greetings, I have been playing with trying to change how the carrier listing is displayed, or how I can change the HTML output of my carrier. There are two hooks I have found that relate to this: displayCarrierList displayBeforeCarrier Both seem to basically provide hooks before and after the carrier list during checkout. If I implemented my hookDisplayCarrierList() method like this: public function hookdisplayCarrierList() { return "Test"; } This puts my "TEST" hook after the carrier list, which looks like this: How can I replace the entire listing HTML? Can this only be done by modifying per-template? What I am really trying to do is have custom HTML output for a specific carrier I have implemented in a CarrierModule. Am I looking at this wrong? Link to comment Share on other sites More sharing options...
PascalVG Posted January 4, 2014 Share Posted January 4, 2014 Hi Kris, Can you add some simple image what the end result should look like? Not sure what you exactly mean with " entire listing HTML": Maybe the space between the items, the blocks of each item, like borders, the colour of the background etc? Or something totally different? Please elaborate a little... pascal. Link to comment Share on other sites More sharing options...
krisives Posted January 6, 2014 Author Share Posted January 6, 2014 Here is a (badly) edited image and I will describe what the colors mean: Red: Entire "carrier list" area. Originally I thought to change the layout in my module (not theme) I would have to override this entire area somehow, although I would prefer to have more specific hooks for what I am doing, but if I could replace the entire red area I could accomplish what I want. Teal: Individual hooksto replace each carrier. Here I was hoping to have a hook or module method I could implement that would override how a specific carrier is displayed. Green: This is really the area I am trying to hook into and change. I want to add extra display options, and most likely in the future extra input options (although that is a separate challenge) for more complicated external carriers / display addresses for local pickup etc. Link to comment Share on other sites More sharing options...
krisives Posted January 8, 2014 Author Share Posted January 8, 2014 Bumping allowed? Link to comment Share on other sites More sharing options...
matiit Posted January 9, 2014 Share Posted January 9, 2014 I did this by hiding it with javascript Link to comment Share on other sites More sharing options...
krisives Posted January 9, 2014 Author Share Posted January 9, 2014 (edited) matiit, Other than per-theme template overrides I think that's my only option, other than adding some more hooks to insert content into different areas. PrestaShop doesn't appear to have any way for a module to override templates. Edited January 9, 2014 by krisives (see edit history) 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