Bruce Van Allen skrev/wrote: >Peter R. Wiley wrote: > >>I have set up MacHTTP to test CGI scripts offline (via a "fake" >>connection).[snip] >>The thing is that said script does not print to my browser via MacHTTP >>properly. I assume that the problem is the attempt to print to STDOUT. >>MacHTTP documentation seems to be silent on this point. >> >>Can someone enlighten me as to how to fix the problem? It does not seem to >>be as simple as just changing: >> >> print *STDOUT $line; >> >>to >> >> print $line; >> > >I'd say just try that. > yes, that's the one and only way (AFAIK) >print "Content-type: text/html\n\n" ; # Must have 2 line breaks This shall/must/ought to be print "Content-type: text/html\n\r\n\r" ; which is commonly and wisely coded as print "Content-type: text/html\015\012\015\012"; for portability reasons. Some webservers can deal with two "normal" line breaks, but not all, and if my memory serves me, machttpd is one of those that don't. BTW, did you save your cgi as a cgi with .cgi or .acgi as file extension? This is also a must. Christian icq:19272112 _____________________________________________________ http://www.solvare.se/individer/christian/ soca? soca! http://www.solvare.se/SOCA/ ==== Want to unsubscribe from this list? ==== Send mail with body "unsubscribe" to macperl-webcgi-request@macperl.org