zoukankan      html  css  js  c++  java
  • C#限制上传文件大小

    1.WebConfig:

    限制文件大小为1G

    <system.web>
        <authentication mode="None" />
        <compilation debug="true" targetFramework="4.5.2" />
        <httpRuntime targetFramework="4.5.2" appRequestQueueLimit="100" executionTimeout="80"  maxRequestLength="1073741824" useFullyQualifiedRedirectUrl="false" />
        <httpModules>
          <add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web" />
        </httpModules>
      </system.web>
      <system.webServer>

    2.<system.webServer>下添加:

    <security>
          <requestFiltering>
            <requestLimits maxAllowedContentLength="1073741824"/>
          </requestFiltering>
        </security>

  • 相关阅读:
    7
    6
    5
    3
    4
    2
    1
    寒假工作经历
    软件工程第三周的总结
    软件工程第三周的学习报告 html<input> final finally finalize 的比较 BigInteger
  • 原文地址:https://www.cnblogs.com/tfeblog/p/11606968.html
Copyright © 2011-2022 走看看