Hello there. Im trying to update date by using the helper periodically_call_remote but seems like it doesnt exist anymore on Rails 3. So is there any other way i could do that? -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On 14 January 2011 12:04, Filippos <filipposkip-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hello there. > Im trying to update date by using the helper periodically_call_remote > but seems like it doesnt exist anymore on Rails 3. > So is there any other way i could do that?Googling for rails 3 periodically _call_remote yields many hits and several alternative ways. Colin -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
i tried it but i''ve run into other posts asking the same question. Not any answer related to Rails 3 and Periodically_call_remote On Jan 14, 2:07 pm, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> On 14 January 2011 12:04, Filippos <filippos...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Hello there. > > Im trying to update date by using the helper periodically_call_remote > > but seems like it doesnt exist anymore on Rails 3. > > So is there any other way i could do that? > > Googling for > rails 3 periodically _call_remote > yields many hits and several alternative ways. > > Colin-- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On 14 January 2011 13:33, Filippos <filipposkip-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: Please don''t top post, it makes it difficult to follow the thread. Insert your reply at appropriate points in previous message. Thanks> i tried it but i''ve run into other posts asking the same question. > Not any answer related to Rails 3 and Periodically_call_remotehttp://forums.oreilly.com/content/Head-First-Rails/21079/Periodically-call-remote-Deprecated/#entry38319 http://stackoverflow.com/questions/3661967/rails-3-equivalent-for-periodically-call-remote Colin> > On Jan 14, 2:07 pm, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote: >> On 14 January 2011 12:04, Filippos <filippos...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> >> > Hello there. >> > Im trying to update date by using the helper periodically_call_remote >> > but seems like it doesnt exist anymore on Rails 3. >> > So is there any other way i could do that? >> >> Googling for >> rails 3 periodically _call_remote >> yields many hits and several alternative ways. >> >> Colin > > -- > 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. > 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Curious. I just tried Colin''s suggested Google search term, and got lots of likely-looking results; the top being a stackoverflow post about how to do it with jquery... -- Top-posted from Android On Jan 14, 2011 1:34 PM, "Filippos" <filipposkip-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: i tried it but i''ve run into other posts asking the same question. Not any answer related to Rails 3 and Periodically_call_remote On Jan 14, 2:07 pm, Colin Law <clan...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> On 14 January 2011 12:04, Filippos <filippos...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > >Hello there. > > Im trying... -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Filippos wrote in post #974933:> i tried it but i''ve run into other posts asking the same question. > Not any answer related to Rails 3 and Periodically_call_remoteI''d guess that periodically_call_remote was pulled because it''s directly dependent on the Prototype JavaScript framework. It''s a thin wrapper around Ajax.PeriodicalUpdater. http://api.prototypejs.org/ajax/Ajax/PeriodicalUpdater/ In any case it''s relatively easy to implement that functionality. The JS frameworks don''t even really make it all that much easier than straight up JavaScript. If you really want it back the helper has been extracted to: https://github.com/rails/prototype_legacy_helper ----------------- def periodically_call_remote(options = {}) frequency = options[:frequency] || 10 # every ten seconds by default code = "new PeriodicalExecuter(function() {#{remote_function(options)}}, #{frequency})" javascript_tag(code) end ----------------- As you can see here, all it really does is write out some JavaScript that you could easily write yourself. To make matters worse, the helper writes Obtrusive JavaScript. Rails 3 is has moved to Unobtrusive JavaScript (UJS), which is probably another reason this was extracted. -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.