  |
1 | 1 | | <?php |
| |
2 | 2 | | /* |
  |
3 | | - | $Id: currencies.php 151 2005-08-02 14:33:25Z mattice $ |
| |
| 3 | + | $Id: currencies.php 368 2005-12-22 16:27:23Z hpdl $ |
|
4 | 4 | | |
| |
5 | 5 | | osCommerce, Open Source E-Commerce Solutions |
| |
6 | 6 | | http://www.oscommerce.com |
| |
|
|
 |
… |
|
34 | 34 | | |
| |
35 | 35 | | // class methods |
| |
36 | 36 | | function format($number, $currency_code = '', $currency_value = '') { |
  |
37 | | - | global $osC_Session; |
| |
38 | | - | |
|
39 | 37 | | if (empty($currency_code) || ($this->exists($currency_code) == false)) { |
  |
40 | | - | $currency_code = ($osC_Session->exists('currency') ? $osC_Session->value('currency') : DEFAULT_CURRENCY); |
| |
| 38 | + | $currency_code = (isset($_SESSION['currency']) ? $_SESSION['currency'] : DEFAULT_CURRENCY); |
  |
41 | 39 | | } |
| |
42 | 40 | | |
| |
43 | 41 | | if (empty($currency_value) || (is_numeric($currency_value) == false)) { |