zwacklmann Posted January 8, 2011 Share Posted January 8, 2011 Hi everyone,does anyone know where the $path variable that is being used to create the breadcrumb trail is created?I would like to take out the space before each category link in oder to better be able to controll the layout through css. Link to comment Share on other sites More sharing options...
rocky Posted January 9, 2011 Share Posted January 9, 2011 I'll use the product page breadcrumb as an example. The path variable is created on line 196 of product.php (in PrestaShop v1.3.5): 'path' => ((isset($category->id) AND $category->id) ? Tools::getFullPath(intval($category->id), $product->name) : Tools::getFullPath(intval($product->id_category_default), $product->name)) Which uses the Tools::getFullPath to create the path: static public function getFullPath($id_category, $end) { global $cookie; $pipe = (Configuration::get('PS_NAVIGATION_PIPE') ? Configuration::get('PS_NAVIGATION_PIPE') : '>'); $category = new Category(intval($id_category), intval($cookie->id_lang)); if (!Validate::isLoadedObject($category)) die(self::displayError()); if ($id_category == 1) return htmlentities($end, ENT_NOQUOTES, 'UTF-8'); return self::getPath($id_category, Category::hideCategoryPosition($category->name), true).''.$pipe.' '.htmlentities($end, ENT_NOQUOTES, 'UTF-8').''; } Link to comment Share on other sites More sharing options...
zwacklmann Posted January 9, 2011 Author Share Posted January 9, 2011 That is exactely what I am looking for.Thanks a ton.PrestaRoot/classes/Tools.php Link to comment Share on other sites More sharing options...
rocky Posted January 9, 2011 Share Posted January 9, 2011 Please edit your first post and add [sOLVED] to the front of the title. Link to comment Share on other sites More sharing options...
NemoPS Posted November 9, 2011 Share Posted November 9, 2011 Hi, i'm looking for a solution to add the breadcrumbs in the top of pages, but since the path is assigned in center column, i just get "home" in the head. Any solution? Link to comment Share on other sites More sharing options...
webdents Posted November 12, 2011 Share Posted November 12, 2011 Just use CSS to put the breadcrumb where you need it. You can use negative values to move up and to left. Link to comment Share on other sites More sharing options...
outlet.ee Posted January 20, 2012 Share Posted January 20, 2012 I am looking for removing the product name from the breadcrumb, leaving just the home-category-subcategory, as the prooduct name is mentioned already right below the breadcrumb. Now if I change the 'path' => Tools::getPath((int)$category->id, $this->product->name, true), into 'path' => Tools::getPath((int)$category->id, true), it leaves just '1' for product name. Anyone knows how to remove? Link to comment Share on other sites More sharing options...
Guest Posted February 7, 2012 Share Posted February 7, 2012 I am looking for removing the product name from the breadcrumb, leaving just the home-category-subcategory, as the prooduct name is mentioned already right below the breadcrumb. Now if I change the 'path' => Tools::getPath((int)$category->id, $this->product->name, true), into 'path' => Tools::getPath((int)$category->id, true), it leaves just '1' for product name. Anyone knows how to remove? You need change the line 884 in Classes/Tools.php return $fullPath.$path; To: return $fullPath; Anyone know how move the breadcrumb below top hook?, like the attached image Link to comment Share on other sites More sharing options...
louissss Posted March 15, 2013 Share Posted March 15, 2013 I am looking for a way to add the manufacturer name after the category in the breadcrumb, with a solution that will allow for upgrading prestashop in the future. Can you help me? Thanks Link to comment Share on other sites More sharing options...
www.exclusivepen.eu Posted December 16, 2018 Share Posted December 16, 2018 Hi. I would also like to add a manufacturer name to the breadcrumb product name. PS 1.7.4.2. Can you please help with that? Thank you. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now