[eluser]suba[/eluser]
Hi all,
am using Ajax in CI.
I downloaded Ajax library from CI.
I have one dropdown list. When I change the value from dropdown list, I want to get selected value from dropdown list & using this value I want to check with my table then I want to retrieve some value from table related to my selected value.
My question is,
Using Ajax, How can I get selected value from dropdwon list?
pls advice me.
Code:
<select name='country' id='country' >
<option>United status</option>
<option>India</option>
---------------------
</select>
Then when I select my country, I want show state of the selected country.
Example Now choose India from dropdown list.
then I want to dispaly state list like this
Code:
<select name='state'>
<option>Tamil Nadu</option>
----------------------
</select>
State List , I stored in my table based on the country name. So I want to capture selected country value from dropdown list & I want to match with my table.
Please help to me.
I tried to use these two functions. But I coudn't get solution.
Code:
observe_form($form,$options=null);
remote_function($options)