[Rails] Re: drop downs

Guest
Thu, 27 Apr 2006 02:25:34 -0000

Alan Francis wrote:
> Alan Francis wrote:
>
>> You don''t seem to have a div or span with an id of
country_area.  tthe
>> :update => ... bit of the observe_field is looking to replcace the
>> contents of an element with the results of the action, you need a div
to
>> render into.
>
> Jyst noticed the countray_area id is used inside the partial.  this
> won''t work as the particl needs rendered *into* country_area.  In
your
> case, that should probably be the td(*).
>
> Alan
> (*)But be wary of DOM manipulation and tables in IE

Thanks that seems to work! I also had to change the line in the
controller to use :object rather than :collection

    render(:partial => "country_area", :object =>
@country_areas)

Thanks again