harleybill Posted May 28, 2009 Share Posted May 28, 2009 I have a category that has only one product. Is there a way to skip the category page and go straight to the product page when that category is selected.Thanks for any help. Link to comment Share on other sites More sharing options...
rocky Posted May 28, 2009 Share Posted May 28, 2009 I just had to do this for the project I'm working on. Here is how I did it. Go to modules/blockcategories/category-tree-branch.tpl and change line from {$node.name|escape:htmlall:'UTF-8'} to, for example: {$node.name|escape:htmlall:'UTF-8'} This code will link any category with the name Personalised directly to the product with ID 46. You can modify this code to fit your needs, adding more elseif statements if necessary. If you have multiple categories with the same name, you should use $node.id instead of $node.name. I used name because it is easier to read code. Link to comment Share on other sites More sharing options...
harleybill Posted May 28, 2009 Author Share Posted May 28, 2009 rocky,Thanks for your help.Your code works but also expands all categories in the category block. Link to comment Share on other sites More sharing options...
qasrani Posted May 28, 2009 Share Posted May 28, 2009 Why not put that product directly under the HOME?Sorry, wrong message Link to comment Share on other sites More sharing options...
goobe1 Posted November 13, 2010 Share Posted November 13, 2010 harleybill, did you ever get a solution to your problem? I'm stuck in the same problem. I would like to "Jump straight to the Product section" Help would be appreciated!!! Link to comment Share on other sites More sharing options...
kugi Posted September 5, 2012 Share Posted September 5, 2012 still looking for solution here The code above shows to lines exactly the same! Link to comment Share on other sites More sharing options...
kugi Posted September 6, 2012 Share Posted September 6, 2012 Managed to do an easy fix of my own about time i give something back to the prestashop community hehe, here is the link with the solution in the Spanish forum..... if anybody who still need it doesnt understand spanish, let me know http://www.prestashop.com/forums/topic/185900-solucionado-categoria-con-un-solo-producto-ir-directo-al-producto/?do=findComment&comment=920111 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