Jump to content

marufish

Members
  • Posts

    3
  • Joined

  • Last visited

marufish's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Thanks Rocky for the fast response. The first two action has worked properly, all the Price = 0 changed to "Call for Price". I attached here with the Tools.php tools.js However, when I replace the following code in the line 268 of Product.tpl, some error occurred. 1. Missing product page of the items set to $0 2. The "Shipping" and "Total" items in the shopping cart still remain with "Call for Price" I attached here with the product.tpl for the prestashop theme. May I know if I did it wrong with the location of the code? Here is the coding that I paste into product.tpl {if !$priceDisplay || $priceDisplay == 2} {convertPrice price=$product->getPrice(true, $smarty.const.NULL, 2)} {if $product->getPrice(true, $smarty.const.NULL, 2) > 0}{l s='tax incl.'}{/if} {/if} {if $priceDisplay == 1} {convertPrice price=$product->getPrice(false, $smarty.const.NULL, 2)} {if $product->getPrice(false, $smarty.const.NULL, 2) > 0}{l s='tax excl.'}{/if} {/if} {if $priceDisplay == 2} {convertPrice price=$product->getPrice(false, $smarty.const.NULL, 2)}{if $product->getPrice(false, $smarty.const.NULL, 2) > 0} {l s='tax excl.'}{/if} {/if} {if ($product->reduction_price != 0 || $product->reduction_percent != 0) && ($product->reduction_from == $product->reduction_to OR ($smarty.now|date_format:'%Y-%m-%d' <= $product->reduction_to && $smarty.now|date_format:'%Y-%m-%d' >= $product->reduction_from))} {if !$priceDisplay || $priceDisplay == 2} {convertPrice price=$product->getPriceWithoutReduct()} {if $product->getPriceWithoutReduct() > 0}{l s='tax incl.'}{/if} {/if} {if $priceDisplay == 1} {convertPrice price=$product->getPriceWithoutReduct(true)} {if $product->getPriceWithoutReduct(true) > 0}{l s='tax excl.'}{/if} {/if} tools.js Tools.php product.tpl.txt
  2. Hi! I am looking for the language pack for Malay too. Anyone know if the language pack created for old version of prestashop will be applicable for the new version too?
  3. Hi Rocky, I have check your old post. However, I am wondering if the following instruction still valid for version 1.3.1. The line 176 in version 1.3.1 is the "static public function switchLanguage()" Can you please kindly provide the latest instruction to change the "Price=0, return "Call for Price" for the new prestashop 1.3.1? Or in which section it should be located? Many Thanks, Marufish Instruction from Rocky in the forum http://www.prestashop.com/forums/viewthread/30213/#163653 The way I would do it is to add the following at line 177 of classes/Tools.php (after the “$price =” line): if ($price == 0) return 'Call for price'; and modify js/tools.js in your theme’s directory and add the following to the start of the formatCurrency function: if (price == 0) return 'Call for price'; This will change all $0.00 to ‘Call for price’, but on the product page, it will display as ‘Call for price tax incl.’, so you’ll have to modify product.tpl and the tpls of any other modules if necessary and write something like {if $price != 0}{l s=‘tax incl.’}{/if}. You’ll have to modify modules/blockcart/blockcart.php too, since the totals will display as ‘Call for price’ when nothing is in the cart. {if !$priceDisplay || $priceDisplay == 2} {convertPrice price=$product->getPrice(true, $smarty.const.NULL, 2)} {if $product->getPrice(true, $smarty.const.NULL, 2) > 0}{l s='tax incl.'}{/if} {/if} {if $priceDisplay == 1} {convertPrice price=$product->getPrice(false, $smarty.const.NULL, 2)} {if $product->getPrice(false, $smarty.const.NULL, 2) > 0}{l s='tax excl.'}{/if} {/if} {if $priceDisplay == 2} {convertPrice price=$product->getPrice(false, $smarty.const.NULL, 2)}{if $product->getPrice(false, $smarty.const.NULL, 2) > 0} {l s='tax excl.'}{/if} {/if} {if ($product->reduction_price != 0 || $product->reduction_percent != 0) && ($product->reduction_from == $product->reduction_to OR ($smarty.now|date_format:'%Y-%m-%d' <= $product->reduction_to && $smarty.now|date_format:'%Y-%m-%d' >= $product->reduction_from))} {if !$priceDisplay || $priceDisplay == 2} {convertPrice price=$product->getPriceWithoutReduct()} {if $product->getPriceWithoutReduct() > 0}{l s='tax incl.'}{/if} {/if} {if $priceDisplay == 1} {convertPrice price=$product->getPriceWithoutReduct(true)} {if $product->getPriceWithoutReduct(true) > 0}{l s='tax excl.'}{/if} {/if}
×
×
  • Create New...