zoukankan      html  css  js  c++  java
  • uploadify 上传 大文件没有反映

    大文件上传

    第一步:修改uploadify参数

    1             'fileSizeLimit': '0',//单个文件大小,0为无限制,可接受KB,MB,GB等单位的字符串值
    2             'fileTypeDesc': '文件',//文件描述Image Files
    3             'fileTypeExts': '*.zip; *.rar; *.png',//允许上传的文件类型

    测试,用一个大于30M的文件,进行上传测试。

    二步:修改web.config

    1 <configuration>
    2   <system.web>
    3     <compilation debug="true" targetFramework="4.5" />
    4     <!--maxRequestLength就是文件的最大字符数,最大值不能超过2个G左右,executionTimeout是超时时间--> 
    5     <httpRuntime targetFramework="4.5" maxRequestLength="1073741824" executionTimeout="3600" />
    6   </system.web>
    7 </configuration>

    第三步:添加system.webServer节点

     1 <configuration>
     2   <system.web>
     3     <compilation debug="true" targetFramework="4.5" />
     4     <!--maxRequestLength就是文件的最大字符数,最大值不能超过2个G左右,executionTimeout是超时时间-->
     5     <httpRuntime targetFramework="4.5" maxRequestLength="1073741824" executionTimeout="3600" />
     6   </system.web>
     7   <system.webServer>
     8     <security>
     9       <requestFiltering>
    10         <!--修改服务器允许最大长度-->
    11         <requestLimits maxAllowedContentLength="1073741824"/>
    12       </requestFiltering>
    13     </security>
    14   </system.webServer>
    15 </configuration>
    本地测试到这里就可以了。如果发布 记得修改ISS的 上传文件大小
  • 相关阅读:
    事件处理
    模板语法
    计算属性和侦听器
    Class 与 Style绑定
    Springboot使用redis
    修改docker-toolbox/boot2docker容器镜像
    docker容器如何安装vim
    Maven+Docker,发布到Registry
    Maven + Docker
    Jenkins-SVN + Maven + Docker
  • 原文地址:https://www.cnblogs.com/kainjie/p/4874644.html
Copyright © 2011-2022 走看看