[Skip to main content](#vessel-content)

#   Addresses in Hikashop

##

- **[reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")**
- [![reeses007's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8958-reeses007 "View reeses007's Profile") Topic Author
- [ Offline](/forum/user/8958-reeses007)

Less More

- Posts: 25
- Thank you received: 1
-
-

13 years 10 months ago -  13 years 10 months ago [\#84427](#84427) by [reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")  *[Addresses in Hikashop](/forum/4-how-to/77261-addresses-in-hikashop#84427 "Hi, We are building a customized internal eCommerce website for a company. The company would like their employees to purchase items through their system instead of buying directly to the suppliers.  When an employee register to the site, they choose their office location from a drop down list of addresses.  With your help, we have removed in hikashop the option to update and typing manually different addresses. The user still have the option to change their office address by going to the user profile and choose from the drop list another location.  Everything seems to work fine so far but there is an issue with the shipping address when receiving a confirmation email. The email doesn't show the latest address from the order. It shows up OK in the admin UI though.  &#42;&#42;&#42;&#42; EDITED &#42;&#42;&#42;&#42; After more testing, we noticed that when a user change its address and order an item...the Billing/Shipping address is still the old one when receiving the email confirmation. Although, If the user logout and login, the Billing/Shipping will be correct when receiving an email confirmation. Is there a way to fix this change address issue without login out?  Also, in administrator/components/com&#95;hikashop/views/order/tmpl, our developer is asking which of these files contains the view code for the orders screen?  Thanks!")* was created by *[reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")*

Hi,
We are building a customized internal eCommerce website for a company. The company would like their employees to purchase items through their system instead of buying directly to the suppliers.

When an employee register to the site, they choose their office location from a drop down list of addresses.

With your help, we have removed in hikashop the option to update and typing manually different addresses. The user still have the option to change their office address by going to the user profile and choose from the drop list another location.

Everything seems to work fine so far but there is an issue with the shipping address when receiving a confirmation email. The email doesn't show the latest address from the order. It shows up OK in the admin UI though.

**** EDITED ****
After more testing, we noticed that when a user change its address and order an item...the Billing/Shipping address is still the old one when receiving the email confirmation. Although, If the user logout and login, the Billing/Shipping will be correct when receiving an email confirmation. Is there a way to fix this change address issue without login out?

Also, in administrator/components/com_hikashop/views/order/tmpl, our developer is asking which of these files contains the view code for the orders screen?

Thanks!

Last edit: 13 years 10 months ago by [reeses007](/forum/user/8958-reeses007 "View reeses007's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzc3MjYxLWFkZHJlc3Nlcy1pbi1oaWthc2hvcD90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26395
- Thank you received: 4077
-
- [](http://obsi.dev)
-

13 years 9 months ago [\#85051](#85051) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Addresses in Hikashop](/forum/4-how-to/77261-addresses-in-hikashop#85051 "Hi, We are building a customized internal eCommerce website for a company. The company would like their employees to purchase items through their system instead of buying directly to the suppliers.  When an employee register to the site, they choose their office location from a drop down list of addresses.  With your help, we have removed in hikashop the option to update and typing manually different addresses. The user still have the option to change their office address by going to the user profile and choose from the drop list another location.  Everything seems to work fine so far but there is an issue with the shipping address when receiving a confirmation email. The email doesn't show the latest address from the order. It shows up OK in the admin UI though.  &#42;&#42;&#42;&#42; EDITED &#42;&#42;&#42;&#42; After more testing, we noticed that when a user change its address and order an item...the Billing/Shipping address is still the old one when receiving the email confirmation. Although, If the user logout and login, the Billing/Shipping will be correct when receiving an email confirmation. Is there a way to fix this change address issue without login out?  Also, in administrator/components/com&#95;hikashop/views/order/tmpl, our developer is asking which of these files contains the view code for the orders screen?  Thanks!")*

Hi,

How did you implemented the drop down list ?
If the address is stored in the database there is no reason that a wrong address is send by email.

What do you mean by orders screen ?
Modifying views directly in HikaShop is highly not recommended. Please use the view overrides.
We could not provide right support if you have modified directly views and you can't make updates.

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzc3MjYxLWFkZHJlc3Nlcy1pbi1oaWthc2hvcD90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")**
- [![reeses007's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8958-reeses007 "View reeses007's Profile") Topic Author
- [ Offline](/forum/user/8958-reeses007)

Less More

- Posts: 25
- Thank you received: 1
-
-

13 years 9 months ago [\#85089](#85089) by [reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")  Replied by *[reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")* on topic *[Addresses in Hikashop](/forum/4-how-to/77261-addresses-in-hikashop#85089 "Hi, We are building a customized internal eCommerce website for a company. The company would like their employees to purchase items through their system instead of buying directly to the suppliers.  When an employee register to the site, they choose their office location from a drop down list of addresses.  With your help, we have removed in hikashop the option to update and typing manually different addresses. The user still have the option to change their office address by going to the user profile and choose from the drop list another location.  Everything seems to work fine so far but there is an issue with the shipping address when receiving a confirmation email. The email doesn't show the latest address from the order. It shows up OK in the admin UI though.  &#42;&#42;&#42;&#42; EDITED &#42;&#42;&#42;&#42; After more testing, we noticed that when a user change its address and order an item...the Billing/Shipping address is still the old one when receiving the email confirmation. Although, If the user logout and login, the Billing/Shipping will be correct when receiving an email confirmation. Is there a way to fix this change address issue without login out?  Also, in administrator/components/com&#95;hikashop/views/order/tmpl, our developer is asking which of these files contains the view code for the orders screen?  Thanks!")*

Hi Jerome,
Yes it is stored in the database. It seems that the email notification read the database values when the user login but if the address change during the session, it doesn't query the latest information in the tables.

Here is another example of this issue.

We modified the step.php file. Before the user submit their order, he/she can choose from a drop down list a different shipping destination (the addresses are predefined in the list). See attachment.

We also updated the checkout.php in the controller folder to save the shipping address in the hikashop address table.

Once the user submit the order, everything is working fine. But, in the email notification, the shipping address doesn't show the latest update. When we go in the ui admin, everything is correct (ie: the shipping address is the latest value).

It seems that we need to update or reset something so the email notification so it would query the latest update in the database.

I could PM you the credentials to access the site if you need to see.

Thanks

- [ ![checkout.jpg](/forum/attachment/7916) ](/forum/attachment/7916 "checkout.jpg") [ ](/forum/attachment/7916?download=1 "checkout.jpg")
- [ ![checkout2.jpg](/forum/attachment/7917) ](/forum/attachment/7917 "checkout2.jpg") [ ](/forum/attachment/7917?download=1 "checkout2.jpg")
- [ ![checkout3.jpg](/forum/attachment/7918) ](/forum/attachment/7918 "checkout3.jpg") [ ](/forum/attachment/7918?download=1 "checkout3.jpg")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzc3MjYxLWFkZHJlc3Nlcy1pbi1oaWthc2hvcD90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26395
- Thank you received: 4077
-
- [](http://obsi.dev)
-

13 years 9 months ago [\#85161](#85161) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Addresses in Hikashop](/forum/4-how-to/77261-addresses-in-hikashop#85161 "Hi, We are building a customized internal eCommerce website for a company. The company would like their employees to purchase items through their system instead of buying directly to the suppliers.  When an employee register to the site, they choose their office location from a drop down list of addresses.  With your help, we have removed in hikashop the option to update and typing manually different addresses. The user still have the option to change their office address by going to the user profile and choose from the drop list another location.  Everything seems to work fine so far but there is an issue with the shipping address when receiving a confirmation email. The email doesn't show the latest address from the order. It shows up OK in the admin UI though.  &#42;&#42;&#42;&#42; EDITED &#42;&#42;&#42;&#42; After more testing, we noticed that when a user change its address and order an item...the Billing/Shipping address is still the old one when receiving the email confirmation. Although, If the user logout and login, the Billing/Shipping will be correct when receiving an email confirmation. Is there a way to fix this change address issue without login out?  Also, in administrator/components/com&#95;hikashop/views/order/tmpl, our developer is asking which of these files contains the view code for the orders screen?  Thanks!")*

Hi,

The address in the email is loaded from the order/cart object.
So it is loaded from the database but, during the checkout, the address selected is loaded thanks to the session. Code:

// Get $shipping_address_id = $app-&gt;getUserState( HIKASHOP_COMPONENT.'.shipping_address'); $billing_address_id = $app-&gt;getUserState( HIKASHOP_COMPONENT.'.billing_address'); // Set $app-&gt;setUserState( HIKASHOP_COMPONENT.'.shipping_address', $shipping_address_id); $app-&gt;setUserState( HIKASHOP_COMPONENT.'.billing_address', $billing_address_id);

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

The following user(s) said Thank You: [reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzc3MjYxLWFkZHJlc3Nlcy1pbi1oaWthc2hvcD90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")**
- [![reeses007's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/8958-reeses007 "View reeses007's Profile") Topic Author
- [ Offline](/forum/user/8958-reeses007)

Less More

- Posts: 25
- Thank you received: 1
-
-

13 years 9 months ago -  13 years 9 months ago [\#85309](#85309) by [reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")  Replied by *[reeses007](/forum/user/8958-reeses007 "View reeses007's Profile")* on topic *[Addresses in Hikashop](/forum/4-how-to/77261-addresses-in-hikashop#85309 "Hi, We are building a customized internal eCommerce website for a company. The company would like their employees to purchase items through their system instead of buying directly to the suppliers.  When an employee register to the site, they choose their office location from a drop down list of addresses.  With your help, we have removed in hikashop the option to update and typing manually different addresses. The user still have the option to change their office address by going to the user profile and choose from the drop list another location.  Everything seems to work fine so far but there is an issue with the shipping address when receiving a confirmation email. The email doesn't show the latest address from the order. It shows up OK in the admin UI though.  &#42;&#42;&#42;&#42; EDITED &#42;&#42;&#42;&#42; After more testing, we noticed that when a user change its address and order an item...the Billing/Shipping address is still the old one when receiving the email confirmation. Although, If the user logout and login, the Billing/Shipping will be correct when receiving an email confirmation. Is there a way to fix this change address issue without login out?  Also, in administrator/components/com&#95;hikashop/views/order/tmpl, our developer is asking which of these files contains the view code for the orders screen?  Thanks!")*

Hi it seems to work much better now. Thanks for your pointers.

Last edit: 13 years 9 months ago by [reeses007](/forum/user/8958-reeses007 "View reeses007's Profile").

The following user(s) said Thank You: [Jerome](/forum/user/80-jerome "View Jerome's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzc3MjYxLWFkZHJlc3Nlcy1pbi1oaWthc2hvcD90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.056 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
