From: Chris Ross Date: 2002-04-15T21:46:36+09:00 Subject: Re: mime type On Mon, Apr 15, 2002 at 09:38:27PM +0900, David Alan Black muttered... : Hello -- : : On Mon, 15 Apr 2002, Chris Ross wrote: : : > On Mon, Apr 15, 2002 at 09:21:02PM +0900, Tobias Reif muttered... : > : Hi all, : > : : > : puts "content-type: text/plain\n" : > : : > : doesn't work (server error), but : > : : > : print "content-type: text/plain\n\n" : > : : > : works; why? : > : : > : > because you need atleast one blank line between the headers [which : > content-type is] and the content of the page. It's a webserver/client : > thing. Perfectly normal :) : : Actually it's a Ruby subtlety, in this case :-) Tobi knows about the : blank line. He was trying to get two \n's out of puts by putting one : in explicitly (note that he uses puts in the first case, print in the : second). But see my other response -- the \n gets stripped by puts. Problem of reading the question too fast :) Forgive me, Regards, Chris -- Chris Ross (boris) chris@darkrock.co.uk | ctr@ferite.org http://www.darkrock.co.uk | http://www.ferite.org "I dont suffer from insanity - I enjoy every minute of it..."