From: Milo Thurston Date: 2004-07-08T00:27:35+09:00 Subject: Downloadable file "on the fly" I'd like to have a cgi script produce it's output as a downloadable .csv file rather than displaying it on screen. In perl, I used to do it this way: @stuff = qw(some items in an array); print $cgi->header(-TYPE => 'text/plain', -EXPIRES => 'now', -ATTACHMENT => 'download.csv'); foreach (@stuff) { print "$_\cI"; } exit 0; Any suggestions on doing the same with ruby? A direct translation of the code doesn't seem to be very effective - I get only a blank page. Thanks for any suggestions. -- www.sirwilliamhope.org