Jump to content

jtis

New Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

jtis's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. hi had tried both ways, the result is still the same
  2. hi thanks but the result is still the same it still show "call for price" twice when the retail price is "0.00" it should show "call for price" when the sales price is "0.00" it should be blank appreciate if you could help. thanks in advance
  3. hi I notice that when the sales price is "0.00" it will also show "call for price" which i think it should be blank. would appreciate if anyone can help. following are the codes for sales price and price format function salePrice($normPrice, $salePrice){ global $config; if($config['saleMode']==1){ if($salePrice<$normPrice && $salePrice>0){ return $salePrice; } else { return FALSE; } } elseif($config['saleMode']==2) { $saleValue = $normPrice * ((100-$config['salePercentOff'])/100); if($saleValue<$normPrice && $saleValue>0){ return $saleValue; } else { return FALSE; } } else { return FALSE; } } function priceFormat($price, $dispNull = FALSE){ global $currencyVars; if(is_numeric($price) && $price != 0){ $price = $price * $currencyVars[0]['value']; return $currencyVars[0]['symbolLeft'].sprintf("%.".$currencyVars[0]['decimalPlaces']."f", $price).$currencyVars[0]['symbolRight']; } elseif($dispNull == TRUE) { return $currencyVars[0]['symbolLeft'].sprintf("%.".$currencyVars[0]['decimalPlaces']."f", 0.00).$currencyVars[0]['symbolRight']; } else { return "Call For Price"; } } Thanks in advance
  4. Hi Thanks, had tried updating and uploaded the scripts. and the result is "call for price" appear twice. attached herewith the result for your reference. Thanks again for your help
  5. Hi I have been trying to change the following for my website, so that when my unit price is "0.00" it will show "call for price" but it don't seem to work. Base on the codes, the result was it'll show both "0.00" and "call for price" on my website which is wrong. Would greatly appreciate if anyone can help Thanks in advance priceFormat(0); function priceFormat($price, $dispNull = FALSE){ if(is_numeric($price)){ global $currencyVars; $price = $price * $currencyVars[0]['value']; return $currencyVars[0]['symbolLeft'].sprintf("%.".$currencyVars[0]['decimalPlaces']."f", $price).$currencyVars[0]['symbolRight']; } elseif($dispNull == TRUE){ global $currencyVars; return $currencyVars[0]['symbolLeft'].sprintf("%.".$currencyVars[0]['decimalPlaces']."f",0.00).$currencyVars[0]['symbolRight']; } else { return "Call For Price"; } }
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.