Jump to content
josels

The State field in the address is not saved in some cases

Recommended Posts

Hi,

 

 

I have a very strange problem with PrestaShop 1.6.0.9. When a customer save an address during registration there are times when the "state" (id_state) field seems not store well and instead of keeping the state corresponding to the selected value, keeps the id of the existing first state. There are even times that keeps the field as empty, when it is impossible that the user leave unfilled as it is required. It is a serious problem because shipping costs depends on state.

 

I use the standard registration process (account + address) and the one page checkout, allowing customers registers as guests.

 

Has anyone had this problem at some point? I am confused because it seems completely random and can not find a common point between all cases.

 

 

This is the information about my PrestaShop installation:

 

Installation Type: Update.

PrestaShop Version: 1.6.0.9

Template: Custom.

Code: Original.

PHP version: 5.3.3-7 + squeeze19

MySQL Version: 5.1.73-1

Browser: Indifferent

 

 

Thank you very much. A greeting.

Share this post


Link to post
Share on other sites

hi. have you had any progress with this? we're experiencing this issue also and we can't pinpoint what's causing it. seems random.

Share this post


Link to post
Share on other sites

hi. have you had any progress with this? we're experiencing this issue also and we can't pinpoint what's causing it. seems random.

 

Hi! Unfortunately I have no progress with this, sometimes it happens and sometimes not, which may indicate a problem with the server or the connection to the database, but can not exclude other possibilities... It is frustrating because I can not identify where is the problem. If you find something, please let me know! Thanks!

Share this post


Link to post
Share on other sites

Hi!

 

 

My problem is still there and I could not find the solution... Perhaps the custom theme may be the responsible of this error? I dismissed this possibility because in localhost I can not reproduce the error, but after nearly two months looking for options, nothing can be discarded... I have checked the PrestaShop core files and no one has been modified.

 

If someone other had this problem and solved it, please reply in this topic.

 

 

Thanks so much!! 

Share this post


Link to post
Share on other sites

1.6.1.1. Same problem when user EDIT "state" in cart (on 3rd step of 5). Please, help who know how to fix it!

Edited by Tgz (see edit history)

Share this post


Link to post
Share on other sites

Same problem here. Please if you know solution, tell here. 

 

Thank you

Share this post


Link to post
Share on other sites

Hello:

I've solved with this modification:

 

In the file AddressController.php Replace the line 187:

 

 

                $address->id_state = 0;

 

By this one:

 

 

                $address->id_state = $_POST['id_state'];

Share this post


Link to post
Share on other sites

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More