Jump to content

How to generate a category/subcategory/product slug (##-productname) globally


Recommended Posts

Hi, since this is my first post, let me just say how much I love PrestaShop. So far, using it for virtual products only, I've had NO problems and it's so easy to theme as well!

My question is this:

With any website I like to assign classes and an ID to the body tag (<body id="this-product" class="this-category">) so that I can style an individual page at whim with CSS. With any CMS I would do this dynamically, but I haven't been able to do this yet with PrestaShop.

I tried grabbing the category "rewrite" from the category block but it only gave me the most top level category. :(

Ideally, I'd like to have the individual category, subcategory, and maybe even product slug to work with.

Thanks so much for doing all you do for free. I can't believe the work that goes into the "simplest" things so I do appreciate this product!

  • Like 2
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...