简体   繁体   English

如何配置IIS 8.5以与Asp.Net UpdatePanel一起使用?

[英]How to configure IIS 8.5 to work with Asp.Net UpdatePanel?

I've created an Asp.Net Web forms project and using an UpdatePanel to prevent page postback. 我创建了一个Asp.Net Web窗体项目,并使用UpdatePanel来防止页面回发。 The update panel is working fine in local testing and also working fine in Windows Local IIS but when I deploy on Windows Server 2012 R2 IIS the page posts back and update panel don't work. 更新面板在本地测试中工作正常,在Windows Local IIS中也正常工作,但是当我在Windows Server 2012 R2 IIS上部署时,页面回发并且更新面板不起作用。 I've also debug the HTML page and it shows the error 我还调试了HTML页面,它显示了错误

Sys is Undefined Sys未定义

I'm not able to know if it is the problem from server side or inside the project. 我不知道这是服务器端还是项目内部的问题。 Below is the configuration on System.Web and System.webServer in web.config. 以下是web.config中System.Web和System.webServer上的配置。

<system.web>
    <httpHandlers></httpHandlers>
    <httpRuntime targetFramework="4.5" />
    <httpModules>
      <add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web" />
    </httpModules>
  </system.web>
  <system.webServer>
    <validation validateIntegratedModeConfiguration="false" />
    <modules>
      <remove name="ApplicationInsightsWebTracking" />
      <add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Web.ApplicationInsightsHttpModule, Microsoft.AI.Web" preCondition="managedHandler" />
    </modules>
    <handlers>
      <add name="Ajax" verb="POST,GET" path="ajax/*.ashx" type="Ajax.PageHandlerFactory, Ajax" />
    </handlers>
  </system.webServer>

There was a problem with references of the ScripManager. ScripManager的引用存在问题。 I added the references from packages that were downloaded and it then worked. 我从下载的软件包中添加了引用,然后它起作用了。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM