Totally Zenned
- Join Date:
- Aug 2007
- Location:
- Gijón, Asturias, Spain
- Posts:
- 2,880
- Plugin Contributions:
- 7
Update of session variables from editing account/primary address book details
When editing either the main account details from the account edit page or the address book, some session variables are updated.
As I use the firstname + lastname in my title bar I noticed that they got out of sync while I was testing addresses.
In /pages/account_edit/header_php.php
// reset the session variables
$_SESSION['customer_first_name'] = $firstname;
And in/pages/address_book_process/header_php.php
There are two similar instances of
// register session variables
if (isset($_POST['primary']) && ($_POST['primary'] == 'on')) {
$_SESSION['customer_first_name'] = $firstname;
$_SESSION['customer_country_id'] = $country;
$_SESSION['customer_zone_id'] = (($zone_id > 0) ? (int)$zone_id : '0');
//if (isset($_POST['primary']) && ($_POST['primary'] == 'on'))
$_SESSION['customer_default_address_id'] = $new_address_book_id;
If all these variables are needed elsewhere why are they not all updated similarly (and why not lastname)?
Steve
github.com/torvista: BackupMySQL, Structured Data, Multiple Copy-Move-Delete, Google reCaptcha, Image Checker, Spanish Language Pack and more...