Forum: Rails Engines File_Column Plugins Problem

E5957bc3db9120592c7df5006a796390?d=identicon&s=25 Chintan Shah (Guest)
on 2006-12-05 08:17
Hi all,

  For uploading the file for my web application, i m using the
file_column plugin.
we are using 5 file-column object to upload 5 files. ie

file_column1
file_column2
file_column3
file_column4
file_column5

 but Accrding to my client his requirement is as below,

When uploading a combination of valid and invalid images, the failure
results in no uploading of the good images. Instead of this behavior,
the server should upload the good images and display a failure
notification for the failed image. Currently, the image will not upload,
but the name of the bad image will display as the image.

invalid types means,

1) it's size exceeds the limit 2mb
2) it's neither a type of .jpg nor ,bmp nor .gif nor .png

so now i m trying to solve the 1st constraints, ie

for that, i have made 1 function which check the size of the image file.
Now what i have to do is if it's size is out of limit then that
file_column option will be blank so at the time of database entry that
file_column obejct's value will be null.

so pls can one help me for these, that how can i null it or how can i
blank the file_upload object at server side.

thnx
This topic is locked and can not be replied to.