# Problem posting to a nested resource URL via AJAX

**URL:** <https://www.ruby-forum.com/t/problem-posting-to-a-nested-resource-url-via-ajax/142012>\
**Category:** Rails\
**Created:** [July 2, 2008, 4:30pm UTC](https://www.ruby-forum.com/t/problem-posting-to-a-nested-resource-url-via-ajax/142012 "2008-07-02T16:30:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![df-sean](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/f07891/32.png) [@df-sean](https://www.ruby-forum.com/u/df-sean)\
**Post date:** [July 2, 2008, 4:30pm UTC](https://www.ruby-forum.com/t/problem-posting-to-a-nested-resource-url-via-ajax/142012/1 "2008-07-02T16:30:53Z")

</div>

I want to get an updated list of states depending on the country the  
user selects. I’m using REST so I would like to post to countries/x/  
states where x is the value of the select. I’m trying to use  
observe\_field but I’m getting nowhere with this. (http://  
[pastie.textmate.org/226272](http://pastie.textmate.org/226272))

Any suggestions?

TIA,

Sean
