php - remove wishlist and product compare from Opencart 1.5 -
i using opencart journal theme.
now no longer want 'wishlist' , 'product compare', want disable it.
i tried many options tried following link.
1) http://www.opencart.com/index.php?route=extension/extension/info&extension_id=11879
where deletes code 'wishlist' , 'product compare' using vqmod, not working me journal theme, , never remove functionality completely.
so how please me.
okay, wrote vqmod in last couple of hours. removes wishlist , product compare functionality 'controller' layer, , removes of themes, using default theme's html parts. since don't know theme (and 1 you've mentioned paid-for theme far know), have necessary modifications yourself, remove wishlist , compare links 'view' layer. might work if theme built upon default theme. here is:
<?xml version="1.0" encoding="utf-8"?> <modification> <id>remove wishlist , product compare</id> <version>1.0</version> <vqmver>2.4.0</vqmver> <author>tibor besze</author> <file name="catalog/controller/account/account.php"> <operation error="skip"> <search position="replace"><![cdata[$this->data['text_wishlist'] = $this->language->get('text_wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['wishlist'] = $this->url->link('account/wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file path="catalog/controller/account/" name="login.php,logout.php"> <operation error="skip"> <search position="replace"><![cdata[unset($this->session->data['wishlist']);]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/controller/account/wishlist.php"> <operation error="skip"> <search position="replace"><![cdata[public function index() {]]></search> <add trim="true"><![cdata[ public function index() { $this->redirect($this->url->link('error/not_found', '', 'ssl')); ]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[ public function add() { ]]></search> <add trim="true"><![cdata[ public function add() { $this->redirect($this->url->link('error/not_found', '', 'ssl')); ]]></add> </operation> </file> <file name="catalog/controller/common/footer.php"> <operation error="skip"> <search position="replace"><![cdata[$this->data['text_wishlist'] = $this->language->get('text_wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['wishlist'] = $this->url->link('account/wishlist', '', 'ssl');]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/controller/common/header.php"> <operation error="skip"> <search position="replace"><![cdata[$this->data['text_wishlist'] = sprintf($this->language->get('text_wishlist'), (isset($this->session->data['wishlist']) ? count($this->session->data['wishlist']) : 0));]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['wishlist'] = $this->url->link('account/wishlist', '', 'ssl');]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/controller/module/account.php"> <operation error="skip"> <search position="replace"><![cdata[$this->data['text_wishlist'] = $this->language->get('text_wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['wishlist'] = $this->url->link('account/wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file path="catalog/controller/product/" name="category.php,manufacturer.php,search.php,special.php"> <operation error="skip"> <search position="replace"><![cdata[$this->data['button_wishlist'] = $this->language->get('button_wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['text_compare'] = sprintf($this->language->get('text_compare'), (isset($this->session->data['compare']) ? count($this->session->data['compare']) : 0));]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['button_compare'] = $this->language->get('button_compare');]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['compare'] = $this->url->link('product/compare');]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/controller/product/product.php"> <operation error="skip"> <search position="replace"><![cdata[$this->data['button_wishlist'] = $this->language->get('button_wishlist');]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[$this->data['button_compare'] = $this->language->get('button_compare');]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/view/theme/*/template/account/account.tpl"> <operation error="skip"> <search position="replace"><![cdata[<li><a href="<?php echo $wishlist; ?>"><?php echo $text_wishlist; ?></a></li>]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/view/theme/*/template/common/footer.tpl"> <operation error="skip"> <search position="replace"><![cdata[<li><a href="<?php echo $wishlist; ?>"><?php echo $text_wishlist; ?></a></li>]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/view/theme/*/template/common/header.tpl"> <operation error="skip"> <search position="replace"><![cdata[<a href="<?php echo $wishlist; ?>" id="wishlist-total"><?php echo $text_wishlist; ?></a>]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/view/theme/*/template/module/account.tpl"> <operation error="skip"> <search position="replace"><![cdata[<li><a href="<?php echo $wishlist; ?>"><?php echo $text_wishlist; ?></a></li>]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file path="catalog/view/theme/*/template/product/" name="category.tpl,special.tpl,search.tpl,manufacturer_info.tpl"> <operation error="skip"> <search position="replace"><![cdata[<div class="wishlist"><a onclick="addtowishlist('<?php echo $product['product_id']; ?>');"><?php echo $button_wishlist; ?></a></div>]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[html += ' <div class="wishlist">' + $(element).find('.wishlist').html() + '</div>';]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[html += '<div class="wishlist">' + $(element).find('.wishlist').html() + '</div>';]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[<div class="product-compare"><a href="<?php echo $compare; ?>" id="compare-total"><?php echo $text_compare; ?></a></div>]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[<div class="compare"><a onclick="addtocompare('<?php echo $product['product_id']; ?>');"><?php echo $button_compare; ?></a></div>]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[html += ' <div class="compare">' + $(element).find('.compare').html() + '</div>';]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[html += '<div class="compare">' + $(element).find('.compare').html() + '</div>';]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> <file name="catalog/view/theme/*/template/product/product.tpl"> <operation error="skip"> <search position="replace"><![cdata[<span class="links"><a onclick="addtowishlist('<?php echo $product_id; ?>');"><?php echo $button_wishlist; ?></a><br />]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[<a onclick="addtocompare('<?php echo $product_id; ?>');"><?php echo $button_compare; ?></a></span>]]></search> <add trim="true"><![cdata[]]></add> </operation> <operation error="skip"> <search position="replace"><![cdata[<span> <?php echo $text_or; ?> </span>]]></search> <add trim="true"><![cdata[]]></add> </operation> </file> </modification>
just put in .xml file, , copy vqmod/xml folder. enjoy!
Comments
Post a Comment