|
Posted by Gordon Burditt on 11/19/44 11:47
>I had a hard disc problem last week on my server. I replaced the disc and
>copied al the files to the new hard disc, everything works fine again except
>some php scripts that are using the mail() function. When executing these
>scripts I get this error:
>"500 Internal Server Error
>The server encountered an internal error or misconfiguration and was unable
>to complete your request.
>
>Please contact the server administrator, webmaster@mydomain.com 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."
>
>
>In my logs I find this:malformed header from script. Bad
>header=/home/mydomain/dead.letter...: php-script
The program invoked by the mail() function (often sendmail) is generating
an error message, which is messing up your output since the web server
thinks it is supposed to be a CGI header, but it isn't.
Temporary workaround: output some text
(e.g. <html><head><title>This is a title</title></head><body>\n")
*before* calling the mail function. You will see the error message
text in the output from your page. Then figure out what it means.
*SOMETHING* is wrong with the mail and it's saving it in a dead.letter
file because it can't deliver it.
>Does somebody know what the problem could be?
Gordon L. Burditt
Navigation:
[Reply to this message]
|