zoukankan      html  css  js  c++  java
  • Server Error in '/' Application. .net

    报错原因:

    Runtime Error  
    Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.  

    Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off". 


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

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

    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 --> 

     

    解决办法:

    1.在本机调试好好的,传到网上出现这个问题,请问如何解决? 
    2.如何配置web.config?  
     
    原因是:
      1.web.config上传到服务器后编码的问题!在web.config中写入
    <globalization requestEncoding="GB2312" responseEncoding="GB2312" uiCulture="zh-CN"   culture="zh-CN" fileEncoding="GB2312" />
      2.IIS配置问题.
      3.配置节点中 mode="Off"
    <configuration> 
        <system.web> 
            <customErrors mode="Off"/> 
        </system.web> 
    </configuration> 

    分析加一下代码:(作用)

    <configuration> 
     <system.web> 
     <customErrors mode="Off"/> 
     </system.web> 
    </configuration> 
    加个这样的,就可以看到具体报什么错误,不然不管出什么错,报的都是那样,每人知道是什么错误.不过传网上不能用了,多半是配置问题

     

  • 相关阅读:
    windows上传代码到Gitee
    gitee推送报错error: failed to push some refs to
    socket和http区别
    腿姐考前叮嘱
    20数学真题答案
    windows下如何查看磁盘IO性能 复制于网络上
    初识WCF异常 1
    WCF中DBNull序列化的问题
    在SQL Server数据库之间进行数据导入导出
    在Silverlight中打开网页的几种方法
  • 原文地址:https://www.cnblogs.com/northeastTycoon/p/2784866.html
Copyright © 2011-2022 走看看