raksmart活动促销

分享

写回答

发帖

GOD的客服回信了 帮翻译下 谢谢了呀(已解決問題)

 关闭

英文翻译专版 英文翻译专版 1903 人阅读 | 3 人回复

发表于 2010-9-12 19:31:25 | 显示全部楼层 |阅读模式

I am currently unable to replicate your issue.

By default, our Windows hosting servers display a generic error when any .NET application generates an exception. We display a generic error because the detailed error messages allow a malicious user to obtain sensitive information.



To troubleshoot the error, you can modify your web.config file and specify that a custom error message displays. A custom error message helps you to locate the specific code that is causing the issue.




CAUTION: The code samples we provide below do not constitute a complete web.config file. Do not replace your existing web.config file with the code we provide. Before changing your web.config file, we recommend creating a backup.





Displaying Custom Error Messages / Enabling Detailed Errors on IIS 6



Use the sample code below to display custom error messages on IIS 6:



<configuration>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>





Displaying Custom Error Messages / Enabling Detailed Errors on IIS 7



Use the sample code below to display custom error messages on IIS 7:


<configuration>
    <system.webServer>
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
    </system.webServer>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>







Please let us know if we can assist you in any other way.
Sincerely,
Travis P.
Online Support


Customer Inquiry
呵呵 有点多

[ 本帖最后由 happymeet 于 2010-9-12 07:32 PM 编辑 ]

回答|共 3 个

竹石缘

发表于 2010-9-12 22:13:30 | 显示全部楼层

大意如下,有可能会翻译错,请谅解

我目前无法重复您的问题。
默认情况下,当NET应用程序产生一场的时候,我们的Windows托管服务器会显示一个一般性错误。我们显示这个一个错误,是因为担心允许恶意用户获得你的敏感信息。

要解决该错误,你可以修改你的web.config文件,并指定一个自定义错误信息显示。自定义错误信息可以帮助您找到导致了问题的特定代码。

注意:我们在下面提供一个不完整的web.config文件代码示例。不要用下面提供您的web.config文件代码去替换现有的代码。在改变你的web.config文件之前,我们建议您创建一个备份文件。
显示自定义错误消息/启用在IIS 6的详细错误

使用下面的代码示例在IIS 6上显示自定义错误消息:
<configuration>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>



显示自定义错误消息/启用在IIS 7的详细错误
使用下面的代码示例,使得在IIS 7下显示自定义错误消息:
<configuration>
    <system.webServer>
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
    </system.webServer>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>

请让我们知道是否可以用其它方式去帮助您。

真诚的祝愿
Travis P.
在线支持
客户查询
RAKSmart

happymeet

发表于 2010-9-13 08:51:48 | 显示全部楼层

谢谢了

microsoft

发表于 2010-9-15 10:36:31 | 显示全部楼层

就是说那个错误不是你网站的真正错误信息,要看真正的错误信息,要在web.config文件里面加上下面的代码:

IIS6的

<configuration>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>

IIS7的
<configuration>
    <system.webServer>
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
    </system.webServer>
    <system.web>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
    </system.web>
</configuration>
您需要登录后才可以回帖 登录 | 注册

本版积分规则