zoukankan      html  css  js  c++  java
  • asp.net 大文上传配置

    配置iis的文件上传大小控制:
    
       今天先说一个问题,在window server2008 下配置上传文件的大小,除了工程自身的config外还需要配置一下服务器上的applicationhost.config,路径为C:/Windows/System32/inetsrv/config。在这个文件中我们需要找到我们网站的location配置节
     
    (比如我们的网站名为test,则找到<location path = “test”>),并在该节下的<system.webServer> ->  <security> -> <requestFiltering> 下添加<requestLimits maxAllowedContentLength="2147483648" />,这个maxAllowedContentLength就是你想要设置的上传最大值。保存文件后重新启动网站即可。
     
        上面这个配置是在服务器上传失败后的错误页面提示出来的,不过具体的操作还是查了后才知道,至于怎么能通过iis管理器配置出来,还
     
    有待摸索摸索~~ 
     
         补充:其实如果location path 这个配置节不存在的话可以自己手动添加一下,这个是可以通过iis管理器配置出来,但是我们当时由于进行了一系列的配置,而且我们对2008这个东西实在是不了解,所以具体哪个配置起了作用就不知道了,惭愧惭愧~~。
     
         下面是我们的配置,可以参考参考
     
         <location path="test">
     
            <system.webServer>
     
                <security>
     
                    <authentication>
     
                        <windowsAuthentication enabled="true" />
     
                        <basicAuthentication enabled="true" />
     
                    </authentication>
     
                    <requestFiltering>
     
                      <requestLimits maxAllowedContentLength="2147483648" />
     
                    </requestFiltering>
     
                </security>
     
            </system.webServer>
     
    </location>
  • 相关阅读:
    二项式反演
    快速沃尔什变换
    springMVC的form标签
    springMVC的拦截器配置
    RESTful使用方法
    springMVC数据绑定
    使用spring框架自带的字符拦截器
    将idea中的项目上传至github
    springMVC的使用方式
    springMVC的概述
  • 原文地址:https://www.cnblogs.com/wuyifu/p/3372455.html
Copyright © 2011-2022 走看看