邮件功能生成500内部服务器错误 [英] mail function generates 500 internal server error

查看:97
本文介绍了邮件功能生成500内部服务器错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嘿,


上周我的服务器上出现了硬盘问题。我更换光盘并将文件复制到新硬盘上,一切正常,除了

一些使用mail()函数的php脚本。执行这些

脚本时,我收到此错误:

" 500内部服务器错误

服务器遇到内部错误或配置错误,但无法

来完成你的请求。


请联系服务器管理员,我们******* @ mydomain.com 并告知

他们发生错误的时间,以及你可能做过的任何事情

可能导致错误。


服务器错误日志中可能会提供有关此错误的更多信息。

在我的日志中,我发现:来自脚本的格式错误的标题不好

header = / home / mydomain / dead.letter ...:php-script


有人知道问题是什么吗?

grt,


Lieven

Hey,

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, we*******@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

Does somebody know what the problem could be?

grt,

Lieven

推荐答案

>我有一个上周在我的服务器上的硬盘问题。我更换了光盘和
>I had a hard disc problem last week on my server. I replaced the disc and
将文件复制到新的硬盘上,除了使用mail()函数的一些php脚本外,一切正常。执行这些脚本时,我收到此错误:
500内部服务器错误
服务器遇到内部错误或配置错误,无法完成您的请求。

请与服务器管理员联系, we*******@mydomain.com 并告知
他们发生错误的时间,以及你可能做过的任何可能导致错误的事情。

有关此错误的更多信息可能在服务器错误日志中可用。

在我的日志中,我发现:脚本格式错误的标题。坏
header = / home / mydomain / dead.letter ...:php-script


mail()函数(通常是sendmail)调用的程序正在生成

一条错误消息,因为网络服务器因为
认为它应该是一个CGI标题而搞乱你的输出,但它不是。


临时解决方法:输出一些文本

(例如< html>< head>< title>这是一个标题< / title>< / head>< ; body> \ n")

*在*调用邮件功能之前。您将在页面输出中看到错误消息

text。然后找出它意味着什么。

* SOMETHING *邮件有问题,它将它保存在dead.letter

文件中因为它不能交付它。

有人知道问题是什么吗?
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, we*******@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



Gordon L. Burditt


临时解决方法:输出一些文本
(例如< html>< head>< title>这是一个标题< / title>< / head> < body> \ n")
*在*调用邮件功能之前。您将在页面输出中看到错误消息
文本。然后找出它意味着什么。
* SOMETHING *邮件错误,它将它保存在dead.letter
文件中,因为它无法提供。
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.



我试过这个,但我仍然收到这个错误。在我的php文件中的在线行我/ b $ b是带有邮件功能的行。


grt,


Lieven


I have tried this, but I''m still receiving this error. The online line I
have in my php file is the line with the mail function.

grt,

Lieven


>>临时解决方法:输出一些文本
>> Temporary workaround: output some text
(例如< html>< head>< title>这是一个标题< / title>< / head>< ; body> \ n")
*在*调用邮件功能之前。您将在页面输出中看到错误消息
文本。然后找出它意味着什么。
* SOMETHING *邮件错误,它将它保存在dead.letter
文件中,因为它无法提供。
(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.

<我试过这个,但我仍然收到这个错误。我在php文件中的在线行是带有邮件功能的行。


I have tried this, but I''m still receiving this error. The online line I
have in my php file is the line with the mail function.




当您看到错误消息时,请点击查看源 ;在你的

浏览器中粘贴错误信息的确切文本和所有内容

进入帖子之前。


Gordon L .Burditt



When you see the error message, then click "view source" in your
browser and paste the exact text of the error message and everything
before it into a post.

Gordon L. Burditt


这篇关于邮件功能生成500内部服务器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆