Jump to content

[SOLVED] [error] Unable to add a new address


Recommended Posts



PS is throwing me these errors while creating a new address:

This country requires you to chose a State.
The Zip/Postal code you've entered is invalid. It must follow this format: 00000

The problem is that those fields are not visible in the form.

Digging more into the code, I found out that the javascript variable "countries" is an empty array in statesManagement.js.

I had to move some countries to new zones. Anyway all countries and states are active.


Thank you for any hints.

Edited by jithu (see edit history)
Link to comment
Share on other sites

Issue solved.


My problem was with the "countries" smarty var. My custom module was also creating a smarty variable called "countries" and it was overwriting the original PS smarty variable. To solve this issue, I've renamed my variable and now everything is working as expected.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...