Hi, Im trying to create a feature in my rails project that handles a certain style of image request. My images could potentially be sotred anywhere on a local disk and hence will not have an application server behind them which rules out just storing the urls in the database and calling them. so in theory a page could request an image file by referencing a the number 12345 . what it needs to do then is get this image from disk and return it to the rails project. Is this possible in ruby on rails? -- 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 -~----------~----~----~----~------~----~------~--~---
Hi Chris, Chris Gallagher wrote:> so in theory a page could request an image file > by referencing a the number 12345 . what it needs > to do then is get this image from disk and return it > to the rails project. > > Is this possible in ruby on rails?You can allow a visitor to upload files, but no web app can simply grab files off a visitor''s computer. If visitor uploads are what you''re looking for, see the file_field or file_field_tag methods at http://api.rubyonrails.org/ hth, Bill --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Bill Walton wrote:> Hi Chris, > > Chris Gallagher wrote: > >> so in theory a page could request an image file >> by referencing a the number 12345 . what it needs >> to do then is get this image from disk and return it >> to the rails project. >> >> Is this possible in ruby on rails? > > You can allow a visitor to upload files, but no web app can simply grab > files off a visitor''s computer. If visitor uploads are what you''re > looking > for, see the file_field or file_field_tag methods at > http://api.rubyonrails.org/ > > hth, > BillSorry i must have explained that badly. Basically there are going to be thousands of images, so we dont want to be storing them within our rails /images directory for example and would rather have a section of disk space for that. -- 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 -~----------~----~----~----~------~----~------~--~---