samedi 27 juin 2015

Rails / Paperclip absolute_path from form?

I'm trying to save the absolute_path from the paperclip file attached in a rails form. I want to save it to the database for later use.

I read through the paperclip docs and can't find anything that I think will work. Ruby has a solution for File abstraction in the ruby-docs that I was able to get working in terminal but i'm not sure how to implement it with rails and paperclip in a form.

Any ideas would be appreciated...

Ultimately, the goal is to parse an xml file (nokogiri) and use the file path to tell paperclip where to find the images listed in the xml which are in the same folder.

Aucun commentaire:

Enregistrer un commentaire