大文件上传preventing浏览器超时 [英] Preventing browser timeout on large file uploads
问题描述
我有一个可爱的小文件上传控制我写的,利用一个IFRAME和ASP.NET web表单ASP.NET AJAX。
I have a nice little file upload control I wrote for ASP.NET webforms that utilizes an IFrame and ASP.NET AJAX.
然而,在较大的上载,浏览器超时,才可以完成张贴的形式。
However, on large uploads, the browser times out before it can finish posting the form.
有没有一种方法,我可以增加此?
Is there a way I can increase this?
我不是真的很有趣的替代解决方案,因此不建议出改变整个事情吧。它的工作原理好< 5 MEG上传,我只是想获得它高达约8MB
I'm not really interesting in alternative solutions, so don't suggest changing the entire thing out please. It works good for <5 meg uploads, I'd just like to get it up to about 8mb.
编辑:设置在Page_Load中的超时没有出现任何改变。
Setting the timeout in Page_Load didn't appear to change anything.
推荐答案
您需要更新IIS6和以后数据库设置。最关键的是ASPMaxRequestEntityAllowed把和以字节为单位pssed前$ P $。我强烈推荐的数据库资源管理器进行更改,通过XML在%SYSTEMROOT涉水%\\ SYSTEM32 \\ inetserv \\的Metabase.xml是可能,但。
You need to update a metabase setting on IIS6 and later. The key is " AspMaxRequestEntityAllowed" and is expressed in bytes. I highly recommend the Metabase Explorer to make the change, wading through the XML at %systemroot%\system32\inetserv\metabase.xml is possible though.
数据库资源管理器: http://support.microsoft.com/kb/840671
嗯,也许是我找错了树......你不会做5 MB的文件,如果这是不是已经调整。
Hmmm, perhaps I'm barking up the wrong tree... you wouldn't be doing 5 MB files if that wasn't already adjusted.
它的另一种刺:看到你的web.config:
Another stab at it: see your web.config:
<system.web>
<httpRuntime maxRequestLength="10240" executionTimeout="360"/>
</system.web>
最大请求长度以KB为单位,并执行超时以秒为单位。
Max request length is in kilobytes and execution timeout is in seconds.
这篇关于大文件上传preventing浏览器超时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!