Hey all,
I’m trying to update a div everytime the value of my textbox is changed:
here is _form.rhtml:
Address
<%= text_field 'bookmark', 'address' , :size => 120 %>
<%= render :partial => 'bookmarktitle' %>
<%= observe_field 'bookmark_address',:frequency => 0.5,
:update => 'ajaxtitle',
:url => {:action => 'bookmarkaddress' },
:with => "'url=' + bookmark_address.value" %>
and this is the updated part _bookmarktitle.rhtml:
Title
<%= text_field 'bookmark', 'title' , :value=>@title, :size => 120 %>
the function bookmarktitle:
def bookmarkaddress
@title = “test value”
end
However when I modify champ bookmark_address, nothing happens.
Any idea what’s wrong in my code?
Thanx in advance
Pat