|
How to remove wishlist feature and comparisonThis discussion has been marked as solved |
Hi,
How do you remove the wishlist feature and comparison on the top header and inside the latest modules.
Thanks,
Hello Mario,
Firstly I would like to make it clear that this is not a theme-related functionality but a default OpenCart features. However there is no setting in the admin panel, for example, which allow you to globally disable the Wishlist and Compare features. In order to remove them you have to modify all the files where these feaatures are displayed and remove them from the code. The files that need to be modified are:
catalog/view/theme/multistore/template/common/header.tpl catalog/view/theme/multistore/template/module/bestseller.tpl catalog/view/theme/multistore/template/module/featured.tpl catalog/view/theme/multistore/template/module/latest.tpl catalog/view/theme/multistore/template/module/multicarousel.tpl catalog/view/theme/multistore/template/module/special.tpl catalog/view/theme/multistore/template/product/category.tpl catalog/view/theme/multistore/template/product/manufacturer_info.tpl catalog/view/theme/multistore/template/product/product.tpl catalog/view/theme/multistore/template/product/search.tpl catalog/view/theme/multistore/template/product/manufacturer_info.tpl catalog/view/theme/multistore/template/product/special.tpl
You should remove the code for 'Add to compare' and 'Add to wishlist' from all these files, and also from the header.tpl you have to remove the Wishlist link in the top bar. In most cases the code for 'Add to compare' and 'Add to wishlist' should look like this:
<div class="compare" onclick="addToCompare('<?php echo $product['product_id']; ?>');"></div>
<div class="wishlist" onclick="addToWishList('<?php echo $product['product_id']; ?>');"></div>
Hope this helps.