CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • Available states and provinces
Pages: [1]

Author Topic: Available states and provinces  (Read 1481 times)

stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Available states and provinces
December 02, 2010, 03:09:48 am
I'm struggling to work out how to configure states and provinces so that just the states and provinces for the relevant country are displayed.

Civi says "State/province listings are populated dynamically based on the selected Country for all standard contact address editing forms, as well as for Profile forms which include both a Country and a State/Province field." 

Yet when I use a Profile form with both Country and State/Province fields, the user gets a list of all available states from all countries I have selected, not just their own country. I would like to include all country and all state options on the site but want Civi to present only those options relevant to the user's country.

Can anyone point me in the right direction?

Yashodha Chaku

  • Forum Godess / God
  • Ask me questions
  • *****
  • Posts: 755
  • Karma: 57
    • CiviCRM
Re: Available states and provinces
December 02, 2010, 04:37:52 am
stevethepug :

Can you make sure you have enabled all the Available Countries that correspond to the Available States and Provinces (and vice-versa) in Administer → Configure → Global Settings  → Localization here

HTH
-Yashodha
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Re: Available states and provinces
December 02, 2010, 06:53:39 am
Thank you Yashodha.

I had left the first box blank as I understood that that would mean "all countries". I have now added all the available countries to the box. It doesn't seem to make any difference - all possible states still appear in the drop-down box.

To be clear, both boxes for "Available Countries" and "Available states and provinces" are now completely empty on the left hand side and completely full (ie all available countries listed) on the right hand side. I have tried this a number of different ways without seeing any difference.

Any ideas?


Yashodha Chaku

  • Forum Godess / God
  • Ask me questions
  • *****
  • Posts: 755
  • Karma: 57
    • CiviCRM
Re: Available states and provinces
December 02, 2010, 11:06:52 pm
stevethepug :

Which version of CiviCRM are you using?

-Yashodha
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Re: Available states and provinces
December 03, 2010, 01:47:14 am
I'm using 3.2.3

Thanks for your help

Steve

Kiran Jagtap

  • Ask me questions
  • ****
  • Posts: 533
  • Karma: 51
Re: Available states and provinces
December 06, 2010, 12:55:01 am
Hello Steve,

Basically those countries you set as  'Available Countries'  are listed in country select drop down on profile form.
Now on selecting particular country -> respective states get populated in state select drop down.

So at any time there has to be states listed for single country.

You might want to play with our public demo site and try to replicate the issue here : http://drupal.demo.civicrm.org/

thanks

kiran
You Are Designed To Choose... Defined By Choice.

stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Re: Available states and provinces
December 14, 2010, 09:08:07 am
Thanks Kiran

Yes, I understand how it is supposed to work - but it just doesn't seem to be doing what it's meant to. I can't replicate it on the demo site.

On some profiles it behaves fine. It seems to be just on the initial Drupal registration which is bringing in a Civi profile that it misbehaves and shows all possible states from all countries no matter what country is selected. Unfortunately of course that's the most important place on the site.

We need to go live next week so I'm thinking I'm going to have to drop the state field out of our tables and put in a custom field for users to insert their own values.

If anyone has any other thoughts I'd be delighted to hear them.

Many thanks

Steve


stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Re: Available states and provinces
April 26, 2011, 03:32:13 am
As a postscript to anyone else facing the same problem, I did finally resolve this!

It seems that you need to make sure that the country field appears above the state field in any profiles. That way, it will only show the correct states for the relevant country. Simple in the end!

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • Available states and provinces

This forum was archived on 2017-11-26.