Page 1 of 1

Remove Breadcrumb

Posted: Wed Aug 15, 2018 4:55 am
by FCWC
How to remove breadcrumb V3.x entirely and also individual pages?
(for those people looking just for that)
Every solution I found was for 2.X not for 3.x
From what I did find I assumed I would need to edit product.twig via the theme editor
Removing

Code: Select all

 <ul class="breadcrumb">
    {% for breadcrumb in breadcrumbs %}
    <li><a href="{{ breadcrumb.href }}">{{ breadcrumb.text }}</a></li>
    {% endfor %}
  </ul>
  
did nothing

Also this wouldn't remove it from the other pages anyway.
Assume once I figure this out I will understand how to also remove Category from product page as well.

Re: Remove Breadcrumb

Posted: Wed Aug 15, 2018 9:38 pm
by Dreamvention
Hi

Opencart defines for every page their breadcrumbs separately. So if you went into catalog/view/theme/DEFAULT (i assume you ar editing the default theme)/ template/catalog/product.twig and simply deleted the breadcrumbs codde, then this will delet it only for products.

you will need to repeat this for all other pages like product/category, product/special, product/search, information/information, information/contact ...

also, remember to refresh the cache of your twig. it is located in admin/dashboard top right corner. in the popup click the orange button to refresh cache.

Re: Remove Breadcrumb

Posted: Thu May 23, 2019 11:18 pm
by letxobnav
eh, no you don't, model has nothing to do with this.

the easy fast way is just the twig files which do the displaying, the slower but more thorough way also includes the controllers which construct the breadcrumbs.

Re: Remove Breadcrumb

Posted: Fri May 24, 2019 4:50 am
by Qphoria
You could also just simply hide it with css

Code: Select all

.breadcrumb {display:none; }
Or another non-permanent way would be to use vQmod or ocmod.
Match catalog/controller/*/*.php (error="skip")
and find a common tag that all controllers use:

Code: Select all

$data['column_left'] =
before, add:

Code: Select all

$data['breadcrumbs'] = array();