The Location module is exhibiting a weird bug. When setting a location (Country & Province/State), if I use autocomplete for the Province field, it will only suggest provinces in the selected country.

However, when I change it to a Dropdown, the Province/State field does not change, despite the AJAX refresh clearly working (the Province/State field fades in and out, so the AJAX callback is clearly working).

I've used the Webkit Inspector to check the page and there's no JS errors and there is an AJAX callback (however, since I don't have a base reference from a functional site, I'm not sure what data payload I should be expecting to see in the callback).

EDIT: I figured out a solution, but Drupal Answers won't let me answer my own question for another 6 hours. For the sake of anyone else who may be running into the same issue, I've uploaded the code + explanation in a pastie.

EDIT: Nevermind, that didn't entirely work... Will update once I find a working solution.

1 Answer 1


A friend of mine worked on that issue a while ago, this was the link to the issue. He is now using the Address Field module. I'm personally using address field as well, the country - province/state selections work well in that module.

  • 1
    Yep, I've read through that large issue thread, and I've even updated to the latest Dev revision which includes the patches... No go :(. Unfortunately, the Address Field module doesn't do what I need as I also need to integrate GMaps + Lat/Long coordinates, which Location module supports, but not Address Field.
    – Peter
    Jan 28, 2012 at 2:09
  • I don't want to bring you too far off your topic, but openlayers and geofield can do all that as well. We had a presentation at our local SFDUG group and I'm now personally leaning towards openlayers. The authors just published a great book too: amazon.com/Mapping-Drupal-Alan-Palazzolo/dp/1449308945
    – uwe
    Jan 28, 2012 at 17:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.