Jump to content
Solodin

Removing breadcrumbs on product page

Recommended Posts

Is there a way to disable the breadcrumbs on the product page? I tried to research a few ways but nothing stopped them from appearing.

 

Does anyone know of a way?

post-400165-0-33074000-1347891037_thumb.jpg

Share this post


Link to post
Share on other sites

Open your product.tpl in an editor then find the following line of code

{include file="$tpl_dir./breadcrumb.tpl"}

 

Depending on your theme it should be around line 120.

 

Comment out or remove that line of code and the breadcrumbs will be removed from your product pages.

 

Hope that helps!

 

Marty Shue

Share this post


Link to post
Share on other sites

I deleted that line of code (preview attached) but the breadcrumbs are still present on the product pages.

 

Is there another location that file is called or an option inside the store possibly?

post-400165-0-07883000-1347895062_thumb.jpg

Edited by Solodin (see edit history)

Share this post


Link to post
Share on other sites

#breadcrumb{display:none!important}

 

try the above in your css or if you have a custom theme, it might have a place to put custom css.

Share this post


Link to post
Share on other sites

if you wanto to hide it only on product list page, you have to use

#category .breadcrumb{display:none!important}

Share this post


Link to post
Share on other sites

I want to hide breadcrumb only on product page but in prestaShop 1.6.1.9 it is not like that . 

The breadcrumbs in the newest ps 1.6 version are in header.tpl in 120 line and  it's like this:
 

{if $page_name !='index' && $page_name !='pagenotfound'}
{include file="$tpl_dir./breadcrumb.tpl"}
{/if}

How block displaying breadcrumbs inside IF ?
page_name ? or somethink else ? 

Edited by IgorDev (see edit history)

Share this post


Link to post
Share on other sites

Change it to:

{if $page_name != 'index' && $page_name != 'pagenotfound' && $page_name != 'product'}
{include file="$tpl_dir./breadcrumb.tpl"}
{/if}

Share this post


Link to post
Share on other sites

hello i try to find the 

{include file="$tpl_dir./breadcrumb.tpl"} 

but i cant find it in my tamplate:( 

i look in product.tpl and in header.tpl 

but nop nathing 

 

eny one help 

 

Share this post


Link to post
Share on other sites
hace 7 horas, whoopzies dijo:

hello i try to find the 


{include file="$tpl_dir./breadcrumb.tpl"} 

but i cant find it in my tamplate:( 

i look in product.tpl and in header.tpl 

but nop nathing 

 

eny one help 

 

Indicates the version of Prestashop you use and if you use the template by default.

You can hide by CSS in a simple way

In Prestashop 1.7.3.3 in the /themes/classic/assets/css/custom.css add

#product .breadcrumb {display:none;}

Other option

/themes/classic/templates/_partials/breadcrumb.tpl

Search code

 

<nav data-depth="{$breadcrumb.count}" class="breadcrumb hidden-sm-down">
  <ol itemscope itemtype="http://schema.org/BreadcrumbList">
    {foreach from=$breadcrumb.links item=path name=breadcrumb}
      {block name='breadcrumb_item'}
        <li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
          <a itemprop="item" href="{$path.url}">
            <span itemprop="name">{$path.title}</span>
          </a>
          <meta itemprop="position" content="{$smarty.foreach.breadcrumb.iteration}">
        </li>
      {/block}
    {/foreach}
  </ol>
</nav>

Change by 

{if $page.page_name!='product'}
<nav data-depth="{$breadcrumb.count}" class="breadcrumb hidden-sm-down">
  <ol itemscope itemtype="http://schema.org/BreadcrumbList">
    {foreach from=$breadcrumb.links item=path name=breadcrumb}
      {block name='breadcrumb_item'}
        <li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
          <a itemprop="item" href="{$path.url}">
            <span itemprop="name">{$path.title}</span>
          </a>
          <meta itemprop="position" content="{$smarty.foreach.breadcrumb.iteration}">
        </li>
      {/block}
    {/foreach}
  </ol>
</nav>
{/if}

Other option:

File -> \themes\classic\templates\layouts\layout-both-columns.tpl

Search 

{block name='breadcrumb'}
            {include file='_partials/breadcrumb.tpl'}
          {/block}

Change by

  {if $page.page_name!='product'}  {include file='_partials/breadcrumb.tpl'} {/if}

Sorry for my English

Edited by nadie
update (see edit history)

Share this post


Link to post
Share on other sites
7 hours ago, nadie said:

Indicates the version of Prestashop you use and if you use the template by default.

You can hide by CSS in a simple way

In Prestashop 1.7.3.3 in the /themes/classic/assets/css/custom.css add


#product .breadcrumb {display:none;}

Other option


/themes/classic/templates/_partials/breadcrumb.tpl

Search code

 


<nav data-depth="{$breadcrumb.count}" class="breadcrumb hidden-sm-down">
  <ol itemscope itemtype="http://schema.org/BreadcrumbList">
    {foreach from=$breadcrumb.links item=path name=breadcrumb}
      {block name='breadcrumb_item'}
        <li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
          <a itemprop="item" href="{$path.url}">
            <span itemprop="name">{$path.title}</span>
          </a>
          <meta itemprop="position" content="{$smarty.foreach.breadcrumb.iteration}">
        </li>
      {/block}
    {/foreach}
  </ol>
</nav>

Change by 


{if $page.page_name!='product'}
<nav data-depth="{$breadcrumb.count}" class="breadcrumb hidden-sm-down">
  <ol itemscope itemtype="http://schema.org/BreadcrumbList">
    {foreach from=$breadcrumb.links item=path name=breadcrumb}
      {block name='breadcrumb_item'}
        <li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
          <a itemprop="item" href="{$path.url}">
            <span itemprop="name">{$path.title}</span>
          </a>
          <meta itemprop="position" content="{$smarty.foreach.breadcrumb.iteration}">
        </li>
      {/block}
    {/foreach}
  </ol>
</nav>
{/if}

Sorry for my English

 

hello my englis is also not zo good but i understand 

i use 1.6 

1.7 is for my not good becorse the tamplate is not ready and lots of modules i use are not ready 

and i dont like to spand again all of the € as i dit when i start the shop :)

but i will try to do the ccs code thnx for your time 

 

greetings 

Share this post


Link to post
Share on other sites
hace 20 minutos, whoopzies dijo:

 

hello my englis is also not zo good but i understand 

i use 1.6 

1.7 is for my not good becorse the tamplate is not ready and lots of modules i use are not ready 

and i dont like to spand again all of the € as i dit when i start the shop :)

but i will try to do the ccs code thnx for your time 

 

greetings 

 

If you use Prestashop 1.6..

You must have in the file -> /themes/Your-Template/header.tpl a call to breadcrumb

Code in Prestashop 1.6 with default template

{if $page_name !='index' && $page_name !='pagenotfound'}
						{include file="$tpl_dir./breadcrumb.tpl"}
					{/if}

Change by

En 28/11/2016 a las 9:54 AM, rocky dijo:

Change it to:


{if $page_name != 'index' && $page_name != 'pagenotfound' && $page_name != 'product'}
{include file="$tpl_dir./breadcrumb.tpl"}
{/if}

 

Other option 

File -> /themes/Your-Template/breadcrumb.tpl

Search

{if isset($smarty.capture.path)}{assign var='path' value=$smarty.capture.path}{/if}
<div class="breadcrumb clearfix">
	<a class="home" href="{if isset($force_ssl) && $force_ssl}{$base_dir_ssl}{else}{$base_dir}{/if}" title="{l s='Return to Home'}"><i class="icon-home"></i></a>
	{if isset($path) AND $path}
		<span class="navigation-pipe"{if isset($category) && isset($category->id_category) && $category->id_category == (int)Configuration::get('PS_ROOT_CATEGORY')} style="display:none;"{/if}>{$navigationPipe|escape:'html':'UTF-8'}</span>
		{if $path|strpos:'span' !== false}
			<span class="navigation_page">{$path|@replace:'<a ': '<span itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><a itemprop="url" '|@replace:'data-gg="">': '><span itemprop="title">'|@replace:'</a>': '</span></a></span>'}</span>
		{else}
			{$path}
		{/if}
	{/if}
</div>
{if isset($smarty.get.search_query) && isset($smarty.get.results) && $smarty.get.results > 1 && isset($smarty.server.HTTP_REFERER)}
<div class="pull-right">
	<strong>
		{capture}{if isset($smarty.get.HTTP_REFERER) && $smarty.get.HTTP_REFERER}{$smarty.get.HTTP_REFERER}{elseif isset($smarty.server.HTTP_REFERER) && $smarty.server.HTTP_REFERER}{$smarty.server.HTTP_REFERER}{/if}{/capture}
		<a href="{$smarty.capture.default|escape:'html':'UTF-8'|secureReferrer|regex_replace:'/[\?|&]content_only=1/':''}" name="back">
			<i class="icon-chevron-left left"></i> {l s='Back to Search results for "%s" (%d other results)' sprintf=[$smarty.get.search_query,$smarty.get.results]}
		</a>
	</strong>
</div>
{/if}

Change by

{if $page_name!='product'}
{if isset($smarty.capture.path)}{assign var='path' value=$smarty.capture.path}{/if}
<div class="breadcrumb clearfix">
	<a class="home" href="{if isset($force_ssl) && $force_ssl}{$base_dir_ssl}{else}{$base_dir}{/if}" title="{l s='Return to Home'}"><i class="icon-home"></i></a>
	{if isset($path) AND $path}
		<span class="navigation-pipe"{if isset($category) && isset($category->id_category) && $category->id_category == (int)Configuration::get('PS_ROOT_CATEGORY')} style="display:none;"{/if}>{$navigationPipe|escape:'html':'UTF-8'}</span>
		{if $path|strpos:'span' !== false}
			<span class="navigation_page">{$path|@replace:'<a ': '<span itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><a itemprop="url" '|@replace:'data-gg="">': '><span itemprop="title">'|@replace:'</a>': '</span></a></span>'}</span>
		{else}
			{$path}
		{/if}
	{/if}
</div>
{if isset($smarty.get.search_query) && isset($smarty.get.results) && $smarty.get.results > 1 && isset($smarty.server.HTTP_REFERER)}
<div class="pull-right">
	<strong>
		{capture}{if isset($smarty.get.HTTP_REFERER) && $smarty.get.HTTP_REFERER}{$smarty.get.HTTP_REFERER}{elseif isset($smarty.server.HTTP_REFERER) && $smarty.server.HTTP_REFERER}{$smarty.server.HTTP_REFERER}{/if}{/capture}
		<a href="{$smarty.capture.default|escape:'html':'UTF-8'|secureReferrer|regex_replace:'/[\?|&]content_only=1/':''}" name="back">
			<i class="icon-chevron-left left"></i> {l s='Back to Search results for "%s" (%d other results)' sprintf=[$smarty.get.search_query,$smarty.get.results]}
		</a>
	</strong>
</div>
{/if}
{/if}

Sorry for my English

Share this post


Link to post
Share on other sites

yee thnx man its working 

and i see i have also modules form you :) cool haha 

 

i have one more qwestion about presta 

the out of stock text color how do i chanes it becorse i cant see text in the red eria 

see pic 

 

thnx a lot 

 

greetings 

 

 

Schermafdruk 2018-06-10 00.51.25.png

Schermafdruk 2018-06-10 00.51.53.png

Share this post


Link to post
Share on other sites

yee thnx man its working 

and i see i have also modules form you :) cool haha 

 

i have one more qwestion about presta 

the out of stock text color how do i chanes it becorse i cant see text in the red eria 

see pic 

 

thnx a lot 

 

greetings 

 

 

Schermafdruk 2018-06-10 00.51.25.png

Schermafdruk 2018-06-10 00.51.53.png

 

  • Haha 1

Share this post


Link to post
Share on other sites

hello 

 

how do I get the breadcrumbs away from all pages?

and how do I adjust the color of the text in the product page that it is almost finished?
(not in stock)

Share this post


Link to post
Share on other sites
On 6/9/2018 at 4:52 PM, nadie said:

Indicates the version of Prestashop you use and if you use the template by default.

You can hide by CSS in a simple way

In Prestashop 1.7.3.3 in the /themes/classic/assets/css/custom.css add


#product .breadcrumb {display:none;}

Other option


/themes/classic/templates/_partials/breadcrumb.tpl

Search code

 


<nav data-depth="{$breadcrumb.count}" class="breadcrumb hidden-sm-down">
  <ol itemscope itemtype="http://schema.org/BreadcrumbList">
    {foreach from=$breadcrumb.links item=path name=breadcrumb}
      {block name='breadcrumb_item'}
        <li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
          <a itemprop="item" href="{$path.url}">
            <span itemprop="name">{$path.title}</span>
          </a>
          <meta itemprop="position" content="{$smarty.foreach.breadcrumb.iteration}">
        </li>
      {/block}
    {/foreach}
  </ol>
</nav>

Change by 


{if $page.page_name!='product'}
<nav data-depth="{$breadcrumb.count}" class="breadcrumb hidden-sm-down">
  <ol itemscope itemtype="http://schema.org/BreadcrumbList">
    {foreach from=$breadcrumb.links item=path name=breadcrumb}
      {block name='breadcrumb_item'}
        <li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
          <a itemprop="item" href="{$path.url}">
            <span itemprop="name">{$path.title}</span>
          </a>
          <meta itemprop="position" content="{$smarty.foreach.breadcrumb.iteration}">
        </li>
      {/block}
    {/foreach}
  </ol>
</nav>
{/if}

Other option:

File -> \themes\classic\templates\layouts\layout-both-columns.tpl

Search 


{block name='breadcrumb'}
            {include file='_partials/breadcrumb.tpl'}
          {/block}

Change by


  {if $page.page_name!='product'}  {include file='_partials/breadcrumb.tpl'} {/if}

Sorry for my English

works like a charm! thanks a lot

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More