Jump to content

Left vertical category


Recommended Posts

 

Hello I have two problems:

 

1. (pic1)   I want that in the place where now is ,,Categories" will be allways another name ,,Elegancija Jai" , where can I change a code to do that? I want that when you click on the subcategory, there wont write a category name on the top, but allways will write ,,Elegancija Jai"

 

2. (pic2)  Why when I click on the subcategory, all subcategories will be destruct and shows like one-level menu?

 

post-1009431-0-18634000-1434695759_thumb.png    post-1009431-0-19847500-1434695767_thumb.png

 
Link to comment
Share on other sites

Prestashop is setup so it grabs the current category (if any) as top level
If you want to prevent it you need to modify blockcategories.php

You can either try getting rid of this

$this->setLastVisitedCategory();

 

 

At the beginning of hookLeftCOlumn, or, in the same method, remove this whole block

 

		if ($phpself != null && in_array($phpself, $current_allowed_controllers) && Configuration::get('BLOCK_CATEG_ROOT_CATEGORY') && isset($this->context->cookie->last_visited_category) && $this->context->cookie->last_visited_category)
		{
			$category = new Category($this->context->cookie->last_visited_category, $this->context->language->id);
			if (Configuration::get('BLOCK_CATEG_ROOT_CATEGORY') == 2 && !$category->is_root_category && $category->id_parent)
				$category = new Category($category->id_parent, $this->context->language->id);
			elseif (Configuration::get('BLOCK_CATEG_ROOT_CATEGORY') == 3 && !$category->is_root_category && !$category->getSubCategories($category->id, true))
				$category = new Category($category->id_parent, $this->context->language->id);
		}
		else

Make sure you keep the $category variable defined after that "else" you remove

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...