Re: problem with php-cgi
|> and this is the output:
|>
|> ./prova.cgi
|> X-Powered-By: PHP/4.0.3pl1
|> Content-type: text/html
|>
|> <html>Questo e' solo una prova</html>
|>
|> why apache tel me: Premature end of script headers: ??????
|
|I can't tell you why your script isn't working correctly but Apache is
|upset because you are returning the X-Powered-By header before the
|Content-type header. The Content-type header *must* be first.
|
|The script works from the command line because the command line couldn't
|care less what you return.
|
|The script works as a handler because Apache takes care of sending the
|Content-type header.
|
|The script fails as a cgi because the Content-type header is not
|returned first.
no, I don't think. I put #!/usr/bin/php -q (without header) and i put the
header with "echo" (an with a spece after) and the result is the same...
|
|
|Pete
|--
|http://www.elbnet.com
|ELB Internet Services, Inc.
|Web Design, Computer Consulting, Internet Hosting
|
Reply to: