justicejustine Posted October 18, 2013 Share Posted October 18, 2013 "in All categories" appear on all of my product names and category names and even in updating customer addresses. How do I remove it? I think this is a backoffice setting. I tried removing products from the 'home' category but this still happens. Products are not in all categories. Do you know why this is happening and how to solve it? Please help. Thanks so much! Examples on my site: http://thenotexchange.com/index.php?id_product=11&controller=product "Civil and Criminal Procedure Essay (Court Report) in All categories"http://thenotexchange.com/index.php?id_category=13&controller=category "Engineering in All categories" Link to comment Share on other sites More sharing options...
PrestaNinja Posted October 18, 2013 Share Posted October 18, 2013 Hello Justine, that is strange is the first time I encounter this problem... What is the version of prestashop you are using? Are you using default theme? Link to comment Share on other sites More sharing options...
justicejustine Posted October 18, 2013 Author Share Posted October 18, 2013 I'm using 1.5.3. Yep, I'm using the default theme Link to comment Share on other sites More sharing options...
PrestaNinja Posted October 18, 2013 Share Posted October 18, 2013 In controllers/front/CategoryController.php, please copy all lines starting from: public function assignProductList 1 Link to comment Share on other sites More sharing options...
justicejustine Posted October 18, 2013 Author Share Posted October 18, 2013 public function assignProductList() { $hookExecuted = false; Hook::exec('actionProductListOverride', array( 'nbProducts' => &$this->nbProducts, 'catProducts' => &$this->cat_products, 'hookExecuted' => &$hookExecuted, )); // The hook was not executed, standard working if (!$hookExecuted) { $this->context->smarty->assign('categoryNameComplement', ''); $this->nbProducts = $this->category->getProducts(null, null, null, $this->orderBy, $this->orderWay, true); $this->pagination((int)$this->nbProducts); // Pagination must be call after "getProducts" $this->cat_products = $this->category->getProducts($this->context->language->id, (int)$this->p, (int)$this->n, $this->orderBy, $this->orderWay); } // Hook executed, use the override else // Pagination must be call after "getProducts" $this->pagination($this->nbProducts); foreach ($this->cat_products as &$product) { if ($product['id_product_attribute'] && isset($product['product_attribute_minimal_quantity'])) $product['minimal_quantity'] = $product['product_attribute_minimal_quantity']; } $this->context->smarty->assign('nb_products', $this->nbProducts); } } Thanks so much, PrestaNinja! Link to comment Share on other sites More sharing options...
vekia Posted October 18, 2013 Share Posted October 18, 2013 problem solved with code above? Link to comment Share on other sites More sharing options...
justicejustine Posted October 18, 2013 Author Share Posted October 18, 2013 No, the code above is the code in controllers/front/CategoryController.php . It isn't solved. Any idea, Vekia? Link to comment Share on other sites More sharing options...
PrestaNinja Posted October 18, 2013 Share Posted October 18, 2013 problem solved with code above? Not yet Could you copy here what is inside <h1>..Copy this..</h1> in files "themes/default/product.tpl" and "themes/default/category.tpl" And do you use the module "layered navigation"? 1 Link to comment Share on other sites More sharing options...
justicejustine Posted October 18, 2013 Author Share Posted October 18, 2013 product.tpl <h1>{$product->name|escape:'htmlall':'UTF-8'}</h1> category.tpl {if $category->id AND $category->active} <h1> {strip} {$category->name|escape:'htmlall':'UTF-8'} {if isset($categoryNameComplement)} {$categoryNameComplement|escape:'htmlall':'UTF-8'} {/if} {/strip} </h1> Thanks PrestaNinja! Yep, I use layered navigation but I've never configured it. Link to comment Share on other sites More sharing options...
PrestaNinja Posted October 18, 2013 Share Posted October 18, 2013 Ok, everything is fine. I was able to trace this text. It is dynamically added when the page loads. I think it is added by your superfish module, could you check superfish configuration? If there is a kind of a search box option try to disable it. But first to make sure that it is the culprit, just desactivate it (don't uninstall). Then clear cache and check page again. 1 Link to comment Share on other sites More sharing options...
justicejustine Posted October 18, 2013 Author Share Posted October 18, 2013 Oh thanks! I bought this module for ajax category search and it was indeed interfering with the pages. What a pity though, because I really want to use it. I wonder if there's a way to modify the module to make it work with the site. Thanks PrestaNinja! Link to comment Share on other sites More sharing options...
Recommended Posts