Hi, It is possible to use a progess bar, but not only for uploading file??? like long calculation time or database access??? Thanks you very much!!! sayoyo -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
If you use Ajax calls, you can specify the :before and :after parameters to show and hide a spinner/timer graphic. If you need to actually show the % of work/file completed, you''ll need to setup a process which has the status available, and call perdiocally_call_remote to check with the server what the status is (assuming its taking longer then regular client/server communication). The returning value would be a percentage/fraction, and you display a graphic associated with that percentage. If you want to get sophisticated, you may be able to run threads to split the progress Hope this helps. Bart --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Hi, thanks you very much for the information, Do you know where can I find the doc.(how to , examples, etc) about what you have told me??? Thanks you!!!! sayoyo Bart Gajderowicz wrote:> If you use Ajax calls, you can specify the :before and :after > parameters to show and hide a spinner/timer graphic. > > If you need to actually show the % of work/file completed, you''ll need > to setup a process which has the status available, and call > perdiocally_call_remote to check with the server what the status is > (assuming its taking longer then regular client/server communication). > The returning value would be a percentage/fraction, and you display a > graphic associated with that percentage. If you want to get > sophisticated, you may be able to run threads to split the progress > > Hope this helps. > Bart-- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
If you want to execute a long-running process and not have it block the application, you''ll need to use something like backgroundrb (http://backgroundrb.rubyforge.org/). Then you can use a periodically_call_remote ajax callback to grab the status and update the progress bar. Mike On 1/8/07, sayoyo <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> > Hi, thanks you very much for the information, > > Do you know where can I find the doc.(how to , examples, etc) about what > you have told me??? > > Thanks you!!!! > > sayoyo > > > Bart Gajderowicz wrote: > > If you use Ajax calls, you can specify the :before and :after > > parameters to show and hide a spinner/timer graphic. > > > > If you need to actually show the % of work/file completed, you''ll need > > to setup a process which has the status available, and call > > perdiocally_call_remote to check with the server what the status is > > (assuming its taking longer then regular client/server communication). > > The returning value would be a percentage/fraction, and you display a > > graphic associated with that percentage. If you want to get > > sophisticated, you may be able to run threads to split the progress > > > > Hope this helps. > > Bart > > > -- > 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---