PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Hey there, trying to learn php. sorry for the newbie-ness of this one, but i have a ver simple php script that i cannot get past premature ending of script headers in
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>test</title>
</head>
<body>
<?php
// Hello World in PHP
echo 'Hello World!';
?>
</body>
</html>
i have tried from the web_root and from cgi-bin , which i really believe to be set up correctly because i have python cgi scripts that work.
just cannot get the php stuff to go. i use debian linux. and i have phpmyadmin installed and it seems to be working fine.
i just dont get it.
what am i doing wrong?
thanks.
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, nephish@xit.net and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
[Tue Aug 2 19:55:22 2005] [error] (8)Exec format error: exec of /var/www/me/cgi-bin/testphp.php failed
[Tue Aug 2 19:55:22 2005] [error] [client 63.97.188.161] Premature end of script headers: /var/www/me/cgi-bin/testphp.php
looks like one of two possible problems to me. 1) your server's PHP support is down 2) you need to move your script. If you have a directory "/var/www/me/httpdocs/" try putting it in there.
um..... i am the host.
i am already host a couple of sites that use python in the cgi, but php seems to be not working (except for phpmyadmin)
maybe my server is set up wrong.
thanks
oh, ok. its fixed now.
i had to set up another ScriptAlias in the http.conf so the thing would run from the new cgi-bin that i created .
cool.
thanks for your time, gents