Lee Goddard wrote:

I don't know: you're doing this:

 print "Content-type: text/plain\n\n";
 print "Hello World\n";

Does it (probably not) make any difference if
you do a full CRLF, as perldoc perlop:

   For example, most networking protocols expect
   and prefer a CR+LF (""\015\012"" or ""\cM\cJ"") for line terminators,
   and although they often accept just ""\012"", they seldom tolerate just
   ""\015"". If you get in the habit of using ""\n"" for networking, you
   may be burned some day.

SB> Apache already fixes up "\n\n" to the right thing. What it really does
SB> is identifying the Content-type: header, and then adds the terminating
SB> by itself, because it really sends other headers, before adding an
SB> empty new line. So it shouldn't matter if you say "\r\n\r\n" or just
SB> "\n\n", unless there is a bug.

So if Apache (mod_perl) adds this to his script, even
though it is not a mod_perl script, then shouldn't he
be calling it from a <Location> that isn't mod_perl
enabled...?

Sorry, just getting into this Apache module thing....
The script sends the header, which could be multiline and terminates it with an empty new line. By saying 'PerlSendHeader On' you tell mod_perl to parse the headers (which is actually done by an apache functions) and separate them from the body. Apache then adds other headers (Server token, Date, etc) and sends the response as if it was a mod_perl module. Think of Apache::Registry and friends as mod_cgi on mushrooms.

__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com

Reply via email to