开发时候采用slickupload控件都没问题,项目发布到IIS时发生了错误:
Could not contact SlickUpload request progress handler at /SlickUpload.axd
经过半天排除从头看了遍官网文档终于发现是由于IIS配置的问题,由于发布采用了II7而配置则是II6的配置
以下是官方文档摘要
system.web/httpModules & system.webServer/modules
To allow SlickUpload to handle upload requests, you need to add its HttpModule to your application. If you already have other HttpModules in your application, just append the add element to the list.
If you are running IIS 7 integrated mode, you will need to add
the<system.webServer/modules> section. If
you are running on IIS 7 classic mode, older versions of IIS, or
the built-in VS.NET WebDev server, you will need to add
the <system.web/httpModules>. If you want
to support both IIS 7 integrated and other servers, add both
sections. If you do this, make sure to also add
the configuration to disable IIS 7‘s default
validation of the httpModulesSection
The following example shows a
typical <system.web/httpModules> element
with the SlickUpload HttpModule reference. Add this section to the
Web.config as a child of
the <system.web> element.
|
1
2
3 |
<httpModules> <add
name="SlickUploadModule"
type="Krystalware.SlickUpload.Web.SlickUploadModule, Krystalware.SlickUpload"/></httpModules> |
The following example shows
a <system.webServer> element with the
SlickUpload HttpModule reference. Add this section to the
Web.config as a child of
the <configuration> element, or merge
these settings into your
existing <system.webServer/modules> element
if you have one.
|
1
2
3
4
5
6 |
<system.webServer> <validation
validateIntegratedModeConfiguration="false"/> <modules
runAllManagedModulesForAllRequests="true"> <add
name="SlickUploadModule"
type="Krystalware.SlickUpload.Web.SlickUploadModule, Krystalware.SlickUpload"
preCondition="integratedMode"
/> </modules></system.webServer>
|
重新配置后问题解决。
PS:本人采用的是6.1.7版本 传送门
SlickUpload 发布到IIS后报错,布布扣,bubuko.com
原文:http://www.cnblogs.com/zachary-woo/p/3592912.html