<%= observe_field :suggest, :url => { :action => :find_suggestion },
:frequency => 0.25,
:update => :suggest,
:with => 'q'
%>
it will refresh the id "suggest"
if you cann't understand
you can also find observe_field method
2010/4/9 Veena Jose <[email protected]>
> Hai frnds,
> Can we add ajax functionality in a layout?
> I was wondering if someone has an answer for that. In my layout current
> time is displayed.But if the time needs to be updated we have to refresh
> the page.I want it using ajax.
>
> Thanks,
> Veena
> --
> 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]<rubyonrails-talk%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/rubyonrails-talk?hl=en.
>
>
--
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.