So I'm following along with Agile Development with Rails, 2nd edition.
I got the code from pg. 503. I'm not saying this because I think its
right--I'm just saying it because if it doesn't take an argument, I'm
not sure how else to do it....
So I'm following along with Agile Development with Rails, 2nd edition.
I got the code from pg. 503. I'm not saying this because I think its
right--I'm just saying it because if it doesn't take an argument, I'm
not sure how else to do it....
Ron
On Jun 14, 10:02 pm, Chris Olsen <rails-mailing-l...@andreas-s.net>
On page 503 the base_part_of function accepts a filename argument.
I think you could be right about the coffee (although its green tea in
my case), Chris. Just as an aside, do you know what disposition
inline means under send_data on the upload controller?
Just as an aside, do you know what disposition
inline means under send_data on the upload controller?
The inline option is what allow the image to be rendered on the page
rather than downloaded. If instead you set the disposition to
"attachment" it should prompt you to save/open the file.
So my typo was behind the arguments issue...but now that it uploads
it, there is a problem that 'picture' is an undefined local variable
or method in the save action of the upload controller. I'm not sure
why because I defined a picture method for in the picture model. Is
it an issue of scope?
Whoops...I'm the world's worst typist. It turns out that it was just
a typo in the model...picture.field instead of picture_field. Really
need to drink fewer stimulants...
Ron