Hi, I''d like to know what is the easiest and best way to save images and videos (both plural) into a model. Also I''d like to know how to upload and change those videos and images with the active admin gem for an admin interface (the admin is the only one that will access this model). Thank you, Rodrigo -- 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.
Have you considered storing the content outside the database and using filenames with a path to reference them? Peter On Oct 11, 2011 2:30 AM, "Rodrigo Ruiz" <rodrigo.ruiz7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi, I''d like to know what is the easiest and best way to save images > and videos (both plural) into a model. > > Also I''d like to know how to upload and change those videos and images > with the active admin gem for an admin interface (the admin is the > only one that will access this model). > > Thank you, > Rodrigo > > -- > 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. > >-- 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.
But how do I do that so that an admin can upload files at the admin interface? so that this admin doesn''t need to know anything about programming or that setup. On Tuesday, October 11, 2011, Peter Hicks <peter.hicks-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Have you considered storing the content outside the database and usingfilenames with a path to reference them?> > Peter > > On Oct 11, 2011 2:30 AM, "Rodrigo Ruiz" <rodrigo.ruiz7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> >> Hi, I''d like to know what is the easiest and best way to save images >> and videos (both plural) into a model. >> >> Also I''d like to know how to upload and change those videos and images >> with the active admin gem for an admin interface (the admin is the >> only one that will access this model). >> >> Thank you, >> Rodrigo >> >> -- >> 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 torubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org < rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.>> For more options, visit this group athttp://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 torubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org < rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.> For more options, visit this group athttp://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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Add a field for the filename in the model object. populate this with the name of the file uploaded that you''d otherwise put in to the database. An alternative is to store the files in the database as a blob, but what if your database is then full of 20Mb rows? P On Oct 11, 2011 2:30 AM, "Rodrigo Ruiz" <rodrigo.ruiz7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi, I''d like to know what is the easiest and best way to save images > and videos (both plural) into a model. > > Also I''d like to know how to upload and change those videos and images > with the active admin gem for an admin interface (the admin is the > only one that will access this model). > > Thank you, > Rodrigo > > -- > 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. > >-- 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.
how do i upload that file to amazon s3, for example, using the active admin interface? and how do i get that file name? On Tuesday, October 11, 2011, Peter Hicks <peter.hicks-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Add a field for the filename in the model object. populate this with thename of the file uploaded that you''d otherwise put in to the database.> > An alternative is to store the files in the database as a blob, but whatif your database is then full of 20Mb rows?> > P > > On Oct 11, 2011 2:30 AM, "Rodrigo Ruiz" <rodrigo.ruiz7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> >> Hi, I''d like to know what is the easiest and best way to save images >> and videos (both plural) into a model. >> >> Also I''d like to know how to upload and change those videos and images >> with the active admin gem for an admin interface (the admin is the >> only one that will access this model). >> >> Thank you, >> Rodrigo >> >> -- >> 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 torubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org < rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.>> For more options, visit this group athttp://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 torubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org < rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.> For more options, visit this group athttp://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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
I can''t help with that - what do the S3 docs say? On Oct 11, 2011 2:54 PM, "Rodrigo Ruiz" <rodrigo.ruiz7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> how do i upload that file to amazon s3, for example, using the active admin > interface? and how do i get that file name? > > On Tuesday, October 11, 2011, Peter Hicks <peter.hicks-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > Add a field for the filename in the model object. populate this with the > name of the file uploaded that you''d otherwise put in to the database. > > > > An alternative is to store the files in the database as a blob, but what > if your database is then full of 20Mb rows? > > > > P > > > > On Oct 11, 2011 2:30 AM, "Rodrigo Ruiz" <rodrigo.ruiz7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > >> > >> Hi, I''d like to know what is the easiest and best way to save images > >> and videos (both plural) into a model. > >> > >> Also I''d like to know how to upload and change those videos and images > >> with the active admin gem for an admin interface (the admin is the > >> only one that will access this model). > >> > >> Thank you, > >> Rodrigo > >> > >> -- > >> 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org < > rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>. > >> 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org < > rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>. > > 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.