M
M
Mike Diam2016-11-20 11:53:26
opencart
Mike Diam, 2016-11-20 11:53:26

How to determine the category ID on the product page in opencart 1.5 without $_GET['path']?

The product template uses different styles that are enabled for products in specific categories. Categories are defined by id from $_GET path variable.
Recently turned on the CNC and, of course, all the settings have been lost. Question - how to get category ID?
Does anyone have a similar vqmod patch?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
iamDiNGo, 2016-11-20
@iamDiNGo

In opencart, in the database, there is a wonderful table oc_product_to_category, in which each product_id corresponds to a certain category_id. I think you should be able to pull out the category_id for your product ID.

W
web-mechanic, 2016-11-21
@amfetamine

$this->request->get['path'] ? no, have not heard

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question