RadEditor DialogHandler web config entries

1 Answer 148 Views
Editor
Jeff
Top achievements
Rank 2
Iron
Iron
Veteran
Jeff asked on 17 Mar 2022, 12:42 PM

For my application, I had to change the dialoghandler in my web.config and the properties of the RadEditor to get it to function properly.  It was a solution I found here in the forums, as a "Last Resort" solution.

Link:  Telerik RadControls Error: Web.config registration missing! The Telerik dialogs require a HttpHandler registration in the web.config file. | Telerik UI for ASP.NET AJAX

I've implemented it and it has resolved the problem.  What I'd like to know is what exactly does this change do?   I need to be able to understand and explain to others what is happening with this change.

 

 

 

1 Answer, 1 is accepted

Sort by
0
Accepted
Rumen
Telerik team
answered on 17 Mar 2022, 12:57 PM | edited on 17 Mar 2022, 12:57 PM

Hi Jeff,

In friendly URLS, URL rewriting or routing scenarios, it is a pretty common problem to face issues with incorrect paths to the handlers that end with the aspx extension. 

That is why the last resort solution allows the developer to configure the RadEditor control to look for a handler with a different extension that will be not touched by the URL rewrites. In the KB example, the aspx extension is changed to axd, but you can change the extension to whatever string that works for your app:

 

Open the web.config file and replace Telerik.Web.UI.DialogHandler.aspx with Telerik.Web.UI.DialogHandler.custom

XML
<system.web>
  <httpHandlers>
    <add path="Telerik.Web.UI.DialogHandler.custom" type="Telerik.Web.UI.DialogHandler" verb="*" validate="false"/>
  </httpHandlers>
</system.web>
<system.webServer>
  <validation validateIntegratedModeConfiguration="false"/>
  <handlers>
    <remove name="Telerik_Web_UI_DialogHandler_axd"/>
    <add name="Telerik_Web_UI_DialogHandler_custom" path="Telerik.Web.UI.DialogHandler.custom" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode"/>
  </handlers>
</system.webServer>

Set the RadEditor's DialogHandlerUrl property to "~/Telerik.Web.UI.DialogHandler.custom", i.e.

ASP.NET
<telerik:RadEditor ID="RadEditor1" DialogHandlerUrl="~/Telerik.Web.UI.DialogHandler.custom" runat="server"></telerik:RadEditor>

 

Regards,
Rumen
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Jeff
Top achievements
Rank 2
Iron
Iron
Veteran
commented on 18 Mar 2022, 11:37 AM

Rumen,

That helps clear it up.  Thanks for the explanation.

Take care,

Jeff.

Tags
Editor
Asked by
Jeff
Top achievements
Rank 2
Iron
Iron
Veteran
Answers by
Rumen
Telerik team
Share this question
or