Does DotNetNuke 6 support Ajax Control Toolkit?

回眸只為那壹抹淺笑 提交于 2019-12-10 04:17:30

问题


Does anybody have successfully working module in DNN 6 with the Ajax Control Toolkit? My modules stopped working when we migrated from DNN 5.x to to 6.x. Modules compile without errors but I am getting client side script error:

'AjaxControlToolkit requires ASP.NET Ajax 4.0 scripts. Ensure the correct version of the scripts are referenced. If you are using an ASP.NET ScriptManager, switch to the ToolkitScriptManager in AjaxControlToolkit.dll'

Seems like this is conflict with Telerik's controls, according to information that I have found. But I didn't find any info how to fix it.


回答1:


It could work together, but you'll need do some modifications to the core of DNN.

Here the list of things to do:

  • Check that you're using latest version of .Net 4.0 binaries of AjaxControlToolkit (I was able to let it work for DNN 6.0.1 with Telerik 2011.01.519 and ACT September 2011 v4.1.50927)
  • Check that in your web.config you have assembly binding redirects for System.Web.Extensions and System.Web.Extensions.Design to the version 4.0
  • Take DNN source package, find Library\Framework\AJAX.cs, locate method AddScriptManager, instantiation of RadScriptManager in it, for the version 6.0.1 look into line 54. Add one more property initializer: EnableScriptCombine = false. Compile it (in Release configuration, of course), take DotNetNuke.dll and drop into your DNN installation.

You should be done.

Credits goes to Telerik support, despite it's stated there that it should work out of the box starting from 2010.1.625. Not sure, did I get them wrong, or they just reintroduced this bug.

P.S. DNN support promises to release version 6.1.0 in November with updated Telerik controls, which should fix this issue, at least on their opinion.




回答2:


You should be able to use older versions of the ASP.NET AJAX Control Toolkit, but once they start requiring the ToolkitScriptManager, you're out of luck with DNN (though you'll be out of luck with any version of DNN, since there's not a way to override the type of ScriptManager it uses.

Starting with DNN 6, they use Telerik's RadScriptManager. Previously, you could modify the core code to switch out for the ToolkitScriptManager, but now switching out might cause other issues.




回答3:


Just checked with nuke 6.1 and the last version of jaxcontroltoolkit - still the same error. It looks like it's not supported anymore. Sad:(



来源:https://stackoverflow.com/questions/7610380/does-dotnetnuke-6-support-ajax-control-toolkit

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!