costin_yo Posted March 2, 2018 Share Posted March 2, 2018 (edited) Does anyone know how to change the default view to list in product list in prestashop 1.7 ? I want to remove completely the view buttons and set the view as list permanently without the customer being able to change it. I managed to do it in the rudimentary way but I know there is another better way to do it. This is how I did it: I added in theme.css: .grid_list { display: none; } I added in custom.js: $(document).ready( function () { $('#list').trigger("click"); }); My own way is to click on the list view after the page is loaded but I get some kind of strange grid to list change after the page is loaded and I do not want that. Can someone tell me another way to do it ? I would really appreciate. I found how to do it for prestashop 1.6 but there is no global.js file in prestashop 1.7. Thank you Edited March 2, 2018 by costin_yo (see edit history) Link to comment Share on other sites More sharing options...
Daniel Posted September 5, 2018 Share Posted September 5, 2018 Hello! I have the same problem but i find my own "answer". First i hide grid button just as the same as you did. Later I change css for grid view. In file custom.css (your style/assets/css) <code> .col-lg-4 { float: left; width: 100%; text-align: left; } </code> Then i got a "list" view but a little another than default list view. Check it and maybe you'll use it too. And yes, I know it's old topic but maybe my answer will be helpfull to someone in future. Link to comment Share on other sites More sharing options...
Suroiu Posted August 13, 2021 Share Posted August 13, 2021 Hi all, I have the "Extreme Life" theme, and to set up the items default view to list form, I changed in: themes/extremestyle/templates/catalog/listing/product-list.tpl from: <section id="products" class="grid"> to: <section id="products" class="list"> Attention: if you don't have the theme "Extreme Life" the product-list.tpl location should be: themes/YOUR-THEME/templates/catalog/listing/product-list.tpl I hope it helps! Have a nice day! 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