Jump to content
stevel

Country-State Selector

Recommended Posts

Anything in the works to update this to work with the latest release of osC?

 

Would do this myself but wanted to check first in case Steve or someone else had already worked on it.

 

Regards,

Joe

Edited by MooseFruit

Share this post


Link to post
Share on other sites
I haven't looked at this yet, probably won't get to it for a while.I assume you mean 2.2-RC1?
Yes exactly. Wow that was a fast reply. :)

Share this post


Link to post
Share on other sites

After a quick look, I don't see anything obvious to change. The edit for state names can be ignored as Country-State Selector does it much better. What other conflicts do you see?

Share this post


Link to post
Share on other sites

To be honest, I didn't examine the file timestamps to see which would need to be updated for RC1, just assumed RC1 would have newer files. Let me take a look now.

Share this post


Link to post
Share on other sites

Ok, to clarify: to save time I was going to copy the files in the zip package and overwrite the files on my store.

 

So if I go through the readme.htm guide line-by-line, I should be able to successfully implement?

Share this post


Link to post
Share on other sites

I looked at the "patch" instructions, and the only files it edited that I think are relevant are those where you'd be replacing the edited code anyway. So in general I'd say yes. I'll try to find the time to verify this soon.

 

BTW, I have no plans at present to look at 3.0, assuming it is released in my lifetime.

Share this post


Link to post
Share on other sites

Will this contribution work if I have one country only?

 

I want to only have the UK, but want counties to be a drop down list.

 

If anyone knows how to just have the UK, that would be really helpful too!

 

Thanks

 

Lotti

Share this post


Link to post
Share on other sites
Will this contribution work if I have one country only?

 

I want to only have the UK, but want counties to be a drop down list.

 

If anyone knows how to just have the UK, that would be really helpful too!

 

Thanks

 

Lotti

 

Sorry wrong question. I see this contribution will enable me to just have UK, but will it then by default provide a drop down list for Counties?

 

Thanks

Share this post


Link to post
Share on other sites

If you have entered zones for the UK counties (not provided in the default osC installation), then yes. You are aware that the county is optional in a postal address if you have the postcode?

Share this post


Link to post
Share on other sites
If you have entered zones for the UK counties (not provided in the default osC installation), then yes. You are aware that the county is optional in a postal address if you have the postcode?

 

Great thanks. I know it's not a requirement but people still expect to put it - at the moment.

 

I have the zones installed, so the drop down list will automatically appear when I set only UK as active right?

 

Anther questions - on my invoice I get for example in County - England - Oxfordshire, how do I just display the Oxfordshire bit?

 

Thanks a lot

 

Lotti

Share this post


Link to post
Share on other sites

Yes, assuming you set the country code as the default country.

 

osC's default address formatting is incorrect for many countries, UK included. Look at the code for tep_format_address in includes/general.php and look at the definitions of the address formats in the database (there is no UI for this in admin). For my store, I've reworked the format_address routine, added some new format types and added a bunch of new formats associated with countries my store ships to most often. I keep saying that one of these days I'll do a real contrib for address formats, but it's a LOT of work.

 

Or maybe you're asking about the dropdown itself? If so, then it's the way you've entered the zones. The country name should not be in there.

Edited by stevel

Share this post


Link to post
Share on other sites
Yes, assuming you set the country code as the default country.

 

osC's default address formatting is incorrect for many countries, UK included. Look at the code for tep_format_address in includes/general.php and look at the definitions of the address formats in the database (there is no UI for this in admin). For my store, I've reworked the format_address routine, added some new format types and added a bunch of new formats associated with countries my store ships to most often. I keep saying that one of these days I'll do a real contrib for address formats, but it's a LOT of work.

 

Or maybe you're asking about the dropdown itself? If so, then it's the way you've entered the zones. The country name should not be in there.

 

Steve you answered all my questions, thanks, am busy installing.

 

If so, then it's the way you've entered the zones. The country name should not be in there - I was also asking about that. I just installed a contribution for uk counties. If I remove and install World_zones part of this contribution would that sort it out?

 

Thanks for you help, hope you find time for that contribution! :thumbsup:

 

Lotti

Share this post


Link to post
Share on other sites

Installing World Zones will add zones so that the zone pulldown will appear for more countries. My past experience with World Zones has been that many of the zones are incorrectly defined, though it has been a couple of years at least since I last looked at it. You will want to compare the zones it gives to those at the official postal site for your country.

Share this post


Link to post
Share on other sites
Installing World Zones will add zones so that the zone pulldown will appear for more countries. My past experience with World Zones has been that many of the zones are incorrectly defined, though it has been a couple of years at least since I last looked at it. You will want to compare the zones it gives to those at the official postal site for your country.

 

 

This is going to sound stupid, but I can't remember how I uploaded my zones to remove them..

 

I've looked in the zones table bug can't find any for country 222

 

Where else should I look?

 

Thanks

Share this post


Link to post
Share on other sites
It's the "zones" table.

 

Hi, Steve. Thanks for the contrib. It's as awesome as all other posters have stated. I'm having one issue that others have had. . .my default country is United States, but when the page first pops up, the state is still a text box. If I then change the country to be Candad, the drop down box appears and then changing it back to United States also displays the state drop-down. The issue is on the initial load.

 

I read through the whole thread. I'm getting no page errors. Also the refresh code is in place. I do have PWA installed as well as STS. Not sure if the issue has to do with either of those?

 

Any help you can provide would be awesome.

 

Kelly

Share this post


Link to post
Share on other sites
Kelly,

 

That's an interesting symptom. Does United States show as the country selected in the country dropdown on initial load?

 

Hi, Steve. Yep, it does.

Share this post


Link to post
Share on other sites
Hi, Steve. Yep, it does.

 

 

Just to say, thanks for all the help and support - great contrib - working wonderfully!

 

Lotti

Share this post


Link to post
Share on other sites

I am looking for a solution to the second address line. I have this contrib installed, but it uses the "suburb" variable for the second address line. I need to know if I can change up the 2nd address line to: xxxxxx_address_2

 

I know there's a contribution that explains how to do it, but will it have an effect on the coding from this contribution?

 

Hey, stevel please post a solution.

 

Many thanks,

stickypod


Anyone can buy a camera... it's what you do with it that counts!

Sticky Pod

www.stickypod.com

Share this post


Link to post
Share on other sites

This contribution does not "use" SUBURB - that's just there from the default osC. If you want to change this to some other field, go ahead. It doesn't affect Country-State Selector. Just be careful when making edits that you change the correct lines.

Share this post


Link to post
Share on other sites
This contribution does not "use" SUBURB - that's just there from the default osC. If you want to change this to some other field, go ahead. It doesn't affect Country-State Selector. Just be careful when making edits that you change the correct lines.

Thank you. I will post my solution once completed.


Anyone can buy a camera... it's what you do with it that counts!

Sticky Pod

www.stickypod.com

Share this post


Link to post
Share on other sites
Thank you. I will post my solution once completed.

After reviewing the "Automated FedEx Labels" coding, I did not need to add an Address2 to the MySQL database and make all the changes. I simply needed to use the "Suburb" variable to do the same thing. It works great and so does this contrib.

 

Thanks for the fast response Steve

stickypod


Anyone can buy a camera... it's what you do with it that counts!

Sticky Pod

www.stickypod.com

Share this post


Link to post
Share on other sites

Hello,

 

I have read through all 40 pages of this topic and have found other people that have asked the question I would like an answer to, but didn't find any answers.

 

Has anyone found a way to change the default state from the first state to some other state?

 

When the form initial comes up with the default country, I would like it to also come up with a default state. I don't care what the default is for the state, after someone changes the country, but I would like it to be correct when the person first views the current form. Is it possible to make this change and if so, where would I do it?

 

Thanks.

Share this post


Link to post
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

×