Actually question. I want to display Children categories in Shop front but I don't want them in View all manufacturer's products page. How can I disable it? Thank you.
Can enyone advise please at least where to look into it. Probably some code to comment? I tried manufacturers view but no luck.
Manufacturer's products page is category view. Files in com_virtuemart/views/category/tmpl/.
Find solution using Chat GPT o1-preview
On your_template/html/com_virtuemart/category/default.php find the code
// Show child categories
if ($this->showcategory and empty($this->keyword)) {
if (!empty($this->category->haschildren)) {
echo ShopFunctionsF::renderVmSubLayout('categories',array('categories'=>$this->category->children, 'categories_per_row'=>$this->categories_per_row));
}
}
and replace it with
if ($this->showcategory and empty($this->keyword) and !empty($this->category->virtuemart_category_id)) {
if (!empty($this->category->has_children)) {
echo ShopFunctionsF::renderVmSubLayout('categories', array(
'categories' => $this->category->children,
'categories_per_row' => $this->categories_per_row
));
}
}
It's removing chaild categories from shop front and manufacturer's view but still displaying it if you click on main category.