Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

prices are gone...where?


sasha23

Recommended Posts

Hello

 

My prices are not displayed on catalog, shopping cart, order email and so on. i can see them in admin and in the database. checked everything, the only thing i get when i look at the source page is <td align="right" class="productListing-data">  </td> and there should be the price..anyone can help me? i think i might have deleted some code. version Rc2.2

thanks

Link to comment
Share on other sites

$currencies->display_price is the function.

 

function display_price($products_price, $products_tax, $quantity = 1) {

return $this->format($this->calculate_price($products_price, $products_tax, $quantity));

}

 

function calculate_price($products_price, $products_tax, $quantity = 1) {

global $currency;

 

return tep_round(tep_add_tax($products_price, $products_tax), $this->currencies[$currency]['decimal_places']) * $quantity;

}

function format($number, $calculate_currency_value = true, $currency_type = '', $currency_value = '') {

global $currency;

 

if (empty($currency_type)) $currency_type = $currency;

 

if ($calculate_currency_value == true) {

$rate = (tep_not_null($currency_value)) ? $currency_value : $this->currencies[$currency_type]['value'];

$format_string = $this->currencies[$currency_type]['symbol_left'] . number_format(tep_round($number * $rate, $this->currencies[$currency_type]['decimal_places']), $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];

} else {

$format_string = $this->currencies[$currency_type]['symbol_left'] . number_format(tep_round($number, $this->currencies[$currency_type]['decimal_places']), $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];

}

 

return $format_string;

}

 

 

these three functions in currency class is where You need to analyse.

 

Satish

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Link to comment
Share on other sites

$currencies->display_price is the function.

 

function display_price($products_price, $products_tax, $quantity = 1) {

return $this->format($this->calculate_price($products_price, $products_tax, $quantity));

}

 

function calculate_price($products_price, $products_tax, $quantity = 1) {

global $currency;

 

return tep_round(tep_add_tax($products_price, $products_tax), $this->currencies[$currency]['decimal_places']) * $quantity;

}

function format($number, $calculate_currency_value = true, $currency_type = '', $currency_value = '') {

global $currency;

 

if (empty($currency_type)) $currency_type = $currency;

 

if ($calculate_currency_value == true) {

$rate = (tep_not_null($currency_value)) ? $currency_value : $this->currencies[$currency_type]['value'];

$format_string = $this->currencies[$currency_type]['symbol_left'] . number_format(tep_round($number * $rate, $this->currencies[$currency_type]['decimal_places']), $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];

} else {

$format_string = $this->currencies[$currency_type]['symbol_left'] . number_format(tep_round($number, $this->currencies[$currency_type]['decimal_places']), $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];

}

 

return $format_string;

}

 

 

these three functions in currency class is where You need to analyse.

 

Satish

thank you ..i will try and see

Link to comment
Share on other sites

Did you delete the USD and not define a new default currency?

no got the problem solved...i have down for maintenance installed and removed the line which was showing the customers when the site will go down...thanks a lot

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...