如何修复客户错误? [英] How do I fix the customerrors 'error'?

查看:69
本文介绍了如何修复客户错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在Microsoft Azure上部署我的系统,并且我一直收到此错误。



<! - Web.Config配置文件 - > ;



< configuration>

< system.web>

< customErrors mode =Off />







注意:您看到的当前错误页面可以替换为通过修改应用程序< customerrors>的defaultRedirect属性来自定义错误页面配置标记指向自定义错误页面URL。





<! - Web.Config配置文件 - > < br $> b $ b

< configuration>

< system.web>

< customErrors mode =RemoteOnlydefaultRedirect =mycustompage.htm/>







我的尝试:



我尝试在Microsoft上部署我的系统。

I am trying to deploy my system on Microsoft Azure, and I keep getting this error.

<!-- Web.Config Configuration File -->

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



Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customerrors> configuration tag to point to a custom error page URL.


<!-- Web.Config Configuration File -->

<configuration>
<system.web>
<customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>



What I have tried:

I have tried deploying my system on Microsoft.

推荐答案

某处出现错误你的代码。默认情况下,ASP.NET不会显示错误的任何细节,因为这会带来安全风险。



您可以按照说明关闭自定义错误在您看到的错误页面上。这将向您网站的任何用户显示任何错误的完整详细信息。



或者,您需要找到一些方法来检查服务器上的错误日志。您如何做到这一点将取决于您的网站托管方式。例如:

启用诊断日志记录对于Azure App Service中的Web应用程序Microsoft Docs [ ^ ]
There's an error somewhere in your code. By default, ASP.NET will not display any details of the error, since this would be a security risk.

You could turn off the custom errors by following the instructions on the error page you're seeing. This would display the full details of any error to any user of your site.

Alternatively, you'll need to find some way to check the error logs on the server. How you do that will depend on precisely how your site is hosted. For example:
Enable diagnostics logging for web apps in Azure App Service | Microsoft Docs[^]


这篇关于如何修复客户错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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