Hi, Does anyone know how to use attachment_fu to upload a file to a folder that is chosen dynamically? i know you can use :path_prefix but this puts all the files in the same folder. I really want the user to choose which folder to upload the file into each time. But I cannot work out how to do it. Can anyone point me in the right direction? Cheers, Tim Fernandez --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
I am getting a bizarre problem using attachment_fu and I was wondering if anyone knows how to fix it/ why its happening. Ive been following: http://clarkware.com/cgi/blosxom/2007/02/24 and I am up and running as far as upload etc goes, but when it comes to display using: <% for mugshot in @mugshots -%> <%= link_to image_tag(mugshot.public_filename(:thumb)), mugshot.public_filename %> <% end -%> I get two images, one is a thumbnail which links to the original file. That is what I want. html: <a href="/image_uploads/0000/0001/test.JPG"><img alt="Test_thumb" src="/image_uploads/0000/0001/test_thumb.JPG?1185027500" /></a> but the other is: <a href="/image_uploads/0000/0001/test_thumb.JPG"><img alt="Test_thumb_thumb" src="/image_uploads/0000/0001/ test_thumb_thumb.JPG" /></a> does anyone know where on earth the ''_thumb_thumb'' came from? and does anyone know how to solve this problem? --~--~---------~--~----~------------~-------~--~----~ 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 7/21/07, fernando <tim.fernandezhart-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > I am getting a bizarre problem using attachment_fu and I was wondering > if anyone knows how to fix it/ why its happening. > > Ive been following: > http://clarkware.com/cgi/blosxom/2007/02/24 > > and I am up and running as far as upload etc goes, but when it comes > to display using: > <% for mugshot in @mugshots -%> > <%= link_to image_tag(mugshot.public_filename(:thumb)), > mugshot.public_filename %> > <% end -%> > > I get two images, one is a thumbnail which links to the original file. > That is what I want. > html: > <a href="/image_uploads/0000/0001/test.JPG"><img alt="Test_thumb" > src="/image_uploads/0000/0001/test_thumb.JPG?1185027500" /></a> > > but the other is: > <a href="/image_uploads/0000/0001/test_thumb.JPG"><img > alt="Test_thumb_thumb" src="/image_uploads/0000/0001/ > test_thumb_thumb.JPG" /></a> > > does anyone know where on earth the ''_thumb_thumb'' came from? > and does anyone know how to solve this problem?@mugshots has the thumbnail too. Filter it by selecting where parent_id is null. -- Rick Olson http://lighthouseapp.com http://weblog.techno-weenie.net http://mephistoblog.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 -~----------~----~----~----~------~----~------~--~---