wbsurfver-/E1597aS9LQAvxtiuMwx3w@public.gmane.org
2006-Dec-02 01:17 UTC
Ajax or similiar file upload ?
I have not been able to get a multiple file upload to work in ajax, and I see a number of references that it can''t be done in ajax because of javascript security, which I now recall. I also have seen references to other ways of doing it using plugins and so on. How hard is it to get one of these plugins to work and what would be a good plug in to use ? What are these plugins using ? I also saw some reference to doing it in iframes ... Any code examples on that ? Here''s sort of what I had tried: <%= form_remote_tag(:update => "uptab", :url => {:action => "image_update", :id => 0, :multipart => true}, :multipart => true) %> ------------------------------------------------------------------------- then someplace else there is something like: <% for idx in 1..@uploads_allowed %> <br/> Select picture: <%= file_field("picture_#{idx}", "picture") %> <br/> <%end%> <%= submit_tag("Upload pictures") %> --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Check out sean treadway''s plugin responds_to_parent AJAX + IFRAME-y goodness: http://sean.treadway.info/svn/plugins/responds_to_parent/README On 12/1/06, wbsurfver-/E1597aS9LQAvxtiuMwx3w@public.gmane.org <wbsurfver-/E1597aS9LQAvxtiuMwx3w@public.gmane.org> wrote:> > > > I have not been able to get a multiple file upload to work in ajax, > and I see a number of references that it can''t be done in ajax because > of javascript security, which I now recall. I also have seen references > to other ways of doing it using plugins and so on. How hard is it to > get one of these plugins to work and what would be a good plug in to > use ? What are these plugins using ? I also saw some reference to doing > it in iframes ... Any code examples on that ? > > > Here''s sort of what I had tried: > > <%= form_remote_tag(:update => "uptab", > :url => {:action => "image_update", :id => 0, > :multipart => true}, > :multipart => true) %> > > ------------------------------------------------------------------------- > > then someplace else there is something like: > > <% for idx in 1..@uploads_allowed %> > > <br/> > Select picture: <%= file_field("picture_#{idx}", "picture") %> > > <br/> > > <%end%> > > <%= submit_tag("Upload pictures") %> > > > > >-- Thanks, -Steve http://www.stevelongdo.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 -~----------~----~----~----~------~----~------~--~---
On 02 Dec 2006, at 02:42, Steve Longdo wrote:> Check out sean treadway''s plugin responds_to_parent AJAX + IFRAME-y > goodness: http://sean.treadway.info/svn/plugins/responds_to_parent/ > READMEIf you''re comfortable with a bit of JavaScript and don''t mind expecting your users to have flash installed, you could have a look at http://labb.dev.mammon.se/swfupload/ It allows upload progress visualisation too. Best regards Peter De Berdt --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---