  |
1 | 1 | | <?php |
| |
2 | 2 | | /* |
  |
3 | | - | $Id: shopping_cart.php 692 2006-08-16 00:53:12Z hpdl $ |
| |
| 3 | + | $Id: shopping_cart.php 732 2006-08-20 00:18:00Z hpdl $ |
|
4 | 4 | | |
| |
5 | 5 | | osCommerce, Open Source E-Commerce Solutions |
| |
6 | 6 | | http://www.oscommerce.com |
| |
|
|
 |
… |
|
528 | 528 | | $previous_address = $this->getShippingAddress(); |
| |
529 | 529 | | } |
| |
530 | 530 | | |
  |
531 | | - | $Qaddress = $osC_Database->query('select ab.entry_firstname, ab.entry_lastname, ab.entry_company, ab.entry_street_address, ab.entry_suburb, ab.entry_postcode, ab.entry_city, ab.entry_zone_id, ab.entry_telephone, z.zone_code, z.zone_name, ab.entry_country_id, c.countries_name, c.countries_iso_code_2, c.countries_iso_code_3, c.address_format_id, ab.entry_state from :table_address_book ab left join :table_zones z on (ab.entry_zone_id = z.zone_id) left join :table_countries c on (ab.entry_country_id = c.countries_id) where ab.customers_id = :customers_id and ab.address_book_id = :address_book_id'); |
| |
| 531 | + | $Qaddress = $osC_Database->query('select ab.entry_firstname, ab.entry_lastname, ab.entry_company, ab.entry_street_address, ab.entry_suburb, ab.entry_postcode, ab.entry_city, ab.entry_zone_id, ab.entry_telephone, z.zone_code, z.zone_name, ab.entry_country_id, c.countries_name, c.countries_iso_code_2, c.countries_iso_code_3, c.address_format, ab.entry_state from :table_address_book ab left join :table_zones z on (ab.entry_zone_id = z.zone_id) left join :table_countries c on (ab.entry_country_id = c.countries_id) where ab.customers_id = :customers_id and ab.address_book_id = :address_book_id'); |
|
532 | 532 | | $Qaddress->bindTable(':table_address_book', TABLE_ADDRESS_BOOK); |
| |
533 | 533 | | $Qaddress->bindTable(':table_zones', TABLE_ZONES); |
| |
534 | 534 | | $Qaddress->bindTable(':table_countries', TABLE_COUNTRIES); |
| |
|
|
 |
… |
|
551 | 551 | | 'country_title' => $Qaddress->value('countries_name'), |
| |
552 | 552 | | 'country_iso_code_2' => $Qaddress->value('countries_iso_code_2'), |
| |
553 | 553 | | 'country_iso_code_3' => $Qaddress->value('countries_iso_code_3'), |
  |
554 | | - | 'format_id' => $Qaddress->valueInt('address_format_id'), |
| |
| 554 | + | 'format' => $Qaddress->value('address_format'), |
|
555 | 555 | | 'telephone_number' => $Qaddress->value('entry_telephone')); |
| |
556 | 556 | | |
| |
557 | 557 | | if ( is_array($previous_address) && ( ($previous_address['id'] != $this->_shipping_address['id']) || ($previous_address['country_id'] != $this->_shipping_address['country_id']) || ($previous_address['zone_id'] != $this->_shipping_address['zone_id']) || ($previous_address['state'] != $this->_shipping_address['state']) || ($previous_address['postcode'] != $this->_shipping_address['postcode']) ) ) { |
| |
|
|
 |
… |
|
616 | 616 | | $previous_address = $this->getBillingAddress(); |
| |
617 | 617 | | } |
| |
618 | 618 | | |
  |
619 | | - | $Qaddress = $osC_Database->query('select ab.entry_firstname, ab.entry_lastname, ab.entry_company, ab.entry_street_address, ab.entry_suburb, ab.entry_postcode, ab.entry_city, ab.entry_zone_id, ab.entry_telephone, z.zone_code, z.zone_name, ab.entry_country_id, c.countries_name, c.countries_iso_code_2, c.countries_iso_code_3, c.address_format_id, ab.entry_state from :table_address_book ab left join :table_zones z on (ab.entry_zone_id = z.zone_id) left join :table_countries c on (ab.entry_country_id = c.countries_id) where ab.customers_id = :customers_id and ab.address_book_id = :address_book_id'); |
| |
| 619 | + | $Qaddress = $osC_Database->query('select ab.entry_firstname, ab.entry_lastname, ab.entry_company, ab.entry_street_address, ab.entry_suburb, ab.entry_postcode, ab.entry_city, ab.entry_zone_id, ab.entry_telephone, z.zone_code, z.zone_name, ab.entry_country_id, c.countries_name, c.countries_iso_code_2, c.countries_iso_code_3, c.address_format, ab.entry_state from :table_address_book ab left join :table_zones z on (ab.entry_zone_id = z.zone_id) left join :table_countries c on (ab.entry_country_id = c.countries_id) where ab.customers_id = :customers_id and ab.address_book_id = :address_book_id'); |
|
620 | 620 | | $Qaddress->bindTable(':table_address_book', TABLE_ADDRESS_BOOK); |
| |
621 | 621 | | $Qaddress->bindTable(':table_zones', TABLE_ZONES); |
| |
622 | 622 | | $Qaddress->bindTable(':table_countries', TABLE_COUNTRIES); |
| |
|
|
 |
… |
|
639 | 639 | | 'country_title' => $Qaddress->value('countries_name'), |
| |
640 | 640 | | 'country_iso_code_2' => $Qaddress->value('countries_iso_code_2'), |
| |
641 | 641 | | 'country_iso_code_3' => $Qaddress->value('countries_iso_code_3'), |
  |
642 | | - | 'format_id' => $Qaddress->valueInt('address_format_id'), |
| |
| 642 | + | 'format' => $Qaddress->value('address_format'), |
  |
643 | 643 | | 'telephone_number' => $Qaddress->value('entry_telephone')); |
| |
644 | 644 | | |
| |
645 | 645 | | if ( is_array($previous_address) && ( ($previous_address['id'] != $this->_billing_address['id']) || ($previous_address['country_id'] != $this->_billing_address['country_id']) || ($previous_address['zone_id'] != $this->_billing_address['zone_id']) || ($previous_address['state'] != $this->_billing_address['state']) || ($previous_address['postcode'] != $this->_billing_address['postcode']) ) ) { |