saideep a.v.s wrote:
> Hello ,
>  Use an Observe_field , so that you can have the country selected as a
> parameter and with the help of the country name u can extract the 
> respective
> cities from the database

> Thanks & Regards,
> 
> Saideep Annadatha

Thanks a tonn saideep for your time and your help. It works great now 
but 1 confusion, actually there are many..lol

1) the :with key in the observe_field, what does it takes and its use? 
Suppose I got combobox displaying camp_location column from the table 
and values as it primary key wich is id. Here :with key takes the value 
of the selected location?

2) I gave :with=>"id" and in the controller, I tried: 
Campsites.find(:all, :condition=>["walk_id = ?",params["id"]]) but 
didn't work but using Campsites.find_by_sql("select * from campsites 
where walk_id = "+params["id"]) did the work. I wonder why?

3) Does it matter to do "id" or :id. For example 
....:update=>:campsites.... <div id = "campsites"> and vice-versa.

4) observe_field, does it use AJAX? coz it only updates the certain area 
of the page and if it does, don't I have to insert 
<%=javascript_include_tag :defaults%>

Thanks..
regards,
jay
-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to