search for: disk_filename

Displaying 1 result from an estimated 1 matches for "disk_filename".

Did you mean: ask_filename
2009 Jul 29
0
Problem uploading file to database mysql blob field
...tachment.rb , just added the line self.file = @temp_file.read as I need to read the content of file and put it into database. def file=(incoming_file) unless incoming_file.nil? @temp_file = incoming_file if @temp_file.size > 0 self.filename = sanitize_filename(@temp_file.original_filename) self.disk_filename = Attachment.disk_filename(filename) self.content_type = @temp_file.content_type.to_s.chomp self.filesize = @temp_file.size self.file = @temp_file.read end end end But After doing so I am getting the following error: Anybody please give some direction ndefined method `original_filename''...