hello everyone,

i have written an upload controller which handles files in a multipart-
form. it scans through the bytes to check if it's an acceptable file.
my problem is to get the progress of the upload of a single file. i
loop through my params to move every file to the server and it's
working properly.

is there a method to check whether a file has been completely
transfered (in rails!)?

regards

--
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@googlegroups.com.
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.

Search Discussions

  • Yan shi at Mar 27, 2012 at 11:26 am
    before u r uploading file,u could get the size of file.so compare the size.

    2012/3/27 Aaron Schmitz <a.schmitz703@googlemail.com>
    hello everyone,

    i have written an upload controller which handles files in a multipart-
    form. it scans through the bytes to check if it's an acceptable file.
    my problem is to get the progress of the upload of a single file. i
    loop through my params to move every file to the server and it's
    working properly.

    is there a method to check whether a file has been completely
    transfered (in rails!)?

    regards

    --
    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@googlegroups.com.
    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.

    --
    *愿爱与喜悦心与你同在!

    石岩敬上
    大连东软信息学院 计算机系软件工程应用方向
    Dalian NEUSOFT Institute of Information
    中国-大连市软件园路8号
    邮编:116023
    **Mail:hlcfan.yan@gmail.com* <hlcfan.yan@gmail.com>
    *Phone:15242613529*

    --
    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@googlegroups.com.
    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.
  • Aaron Schmitz at Mar 27, 2012 at 2:00 pm
    i've got a multipart-form with

    <%= file_field_tag 'objects[]', :id => 'file', :multiple => true %>

    rails does the upload when i click on "go". in firebug i can see that
    there is a post 200 going on and i can see how long the upload takes.
    how can i access this whithout ajax?

    --
    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@googlegroups.com.
    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.
  • Yan shi at Mar 27, 2012 at 2:15 pm
    oh.sorry.u'd better get to know subprocess.certainly,subprocess is a way in
    python.

    2012/3/27 Aaron Schmitz <a.schmitz703@googlemail.com>
    i've got a multipart-form with

    <%= file_field_tag 'objects[]', :id => 'file', :multiple => true %>

    rails does the upload when i click on "go". in firebug i can see that
    there is a post 200 going on and i can see how long the upload takes.
    how can i access this whithout ajax?

    --
    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@googlegroups.com.
    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.

    --
    *愿爱与喜悦心与你同在!

    石岩敬上
    大连东软信息学院 计算机系软件工程应用方向
    Dalian NEUSOFT Institute of Information
    中国-大连市软件园路8号
    邮编:116023
    **Mail:hlcfan.yan@gmail.com* <hlcfan.yan@gmail.com>
    *Phone:15242613529*

    --
    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@googlegroups.com.
    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.
  • Frederick Cheung at Mar 27, 2012 at 6:34 pm

    On 27 Mar 2012, at 14:59, Aaron Schmitz wrote:

    i've got a multipart-form with

    <%= file_field_tag 'objects[]', :id => 'file', :multiple => true %>

    rails does the upload when i click on "go". in firebug i can see that
    there is a post 200 going on and i can see how long the upload takes.
    how can i access this whithout ajax?
    The only way I know of accessing upload progress info is either using a flash uploader or an apache module like https://github.com/drogus/apache-upload-progress-module (there is an equivalent plugin for nginx if my memory is correct)

    Fred
    --
    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@googlegroups.com.
    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@googlegroups.com.
    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.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedMar 27, '12 at 11:22a
activeMar 27, '12 at 6:34p
posts5
users3
websiterubyonrails.org
irc#RubyOnRails

People

Translate

site design / logo © 2022 Grokbase