Solutions Log

So I only have to figure things out once.

Change the Default Folder for File_column to Store Images

Update 2006-12-31: I don’t think this is quite right. It keeps creating a folder in my Rails root as well as in public/. I think I might switch to acts_as_attachment anyway.

In your model, where you define the sizes and whatnot that you want, put:

file_column :database_column_name,
  :store_dir => 'path/you/want',
  :base_url => 'path/you/want',
  (the rest of your configuration)

So what you end up with is images going into rails_root/public/path/you/want/database_id_of_image/

Comments