When I add this code to my aspx ,
<telerik:RadEditor ID="REWelcome" runat="server"
AutoResizeHeight="True" Width="500px" ToolbarMode="Floating">
<Content>
</Content>
<TrackChangesSettings CanAcceptTrackChanges="False"></TrackChangesSettings>
</telerik:RadEditor>
And I got this error message ,
'~/Telerik.Web.UI.WebResource.axd' is missing in web.config.
RadScriptManager requires a
HttpHandler registration in web.config.
How can I solve it ?
In your web.config - add the following to the system.web (omit the system.web, just used to show you level:
<system.web>
<httpHandlers>
<add verb="*" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource, Telerik.Web.UI" validate="false" />
<add verb="*" path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4"></add>
<add verb="*" path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4"></add>
</httpHandlers>
The bottom two are not needed gnerally but I am assuming you want the extended features of the editor, like dialogs and spellchecking.
I also add location at the same level as system.web
<location path="Telerik.Web.UI.WebResource.axd">
<system.web>
<authorization>
<allow users="*" />
</authorization>
</system.web>
</location>
You also have to add the Telerik.Web.UI.dll file in the bin folder of your application.
That worked for me.
These are the handlers needed for RadEditor and RadScriptManager:
<httpHandlers>
<add path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" validate="false"/>
<add path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" validate="false"/>
<add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" validate="false"/>
</httpHandlers>
and
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
<validation validateIntegratedModeConfiguration="false"/>
<handlers>
<add name="Telerik_Web_UI_DialogHandler_aspx" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler"/>
<add name="Telerik_Web_UI_SpellCheckHandler_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler"/>
<add name="Telerik_Web_UI_WebResource_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource"/>
</handlers>
</system.webServer>
source: http://www.telerik.com/forums/telerik-web-ui-webresource-axd-is-missing-in-web-config-f25e27e5a5ac
if the error message is like this::
~/Telerik.Web.UI.WebResource.axd' is missing in web.config. RadScriptManager requires a HttpHandler registration in web.config. Please, use the control Smart Tag to add the handler automatically, or see the help for more information: Controls > RadScriptManager
Then you add the following into your web.config file:::
<httpRuntime targetFramework="4.5.2" />
<httpHandlers>
<add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" validate="false" />
</httpHandlers>
I fixed it by changing the ASP Application pool from "Integrated" to "Classic" mode. All my configurations were correct, as described in other posts here. This is probably specific to my configuration, but may be worth trying.
I came across this issue while deploying to IIS 7.
You could set the Managed pipeline mode from Integrated to Classic. This indeed solves the problem with behaving IIS 7.5 as old 6.0 (with handler registered in old web.config node), but I wasn’t convinced that to use Telerik’s controls, I should use old type of pipeline.
Our old web.config file registered Telerik’s handler only in old section for IIS 6 (and that sufficed for cassini and IIS 6.0) and not in new section.
So I had to add this piece of xml to web.config :
<system.webServer>
<handlers>
<add name="Telerik.Web.UI.WebResource" path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI" />
</handlers>
</system.webServer>
There is a very detailed KB article on this matter including all possible reasons for the error and how to fix it. Please check it out at Error: Web.config registration missing! The Telerik dialogs require a HttpHandler registration in the web.config file.
One of the best solutions is to open the web.config file and replace Telerik.Web.UI.DialogHandler.aspx with Telerik.Web.UI.DialogHandler.axd
<system.web>
<httpHandlers>
<add path="Telerik.Web.UI.DialogHandler.axd" 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_axd" path="Telerik.Web.UI.DialogHandler.axd" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode"/>
</handlers>
</system.webServer>
and after that to set the RadEditor's DialogHandlerUrl property to "~/Telerik.Web.UI.DialogHandler.axd", i.e.
I got this error today when copying a published copy of a site from one server to another.
I figured that I shouldn't have to modify any scripts or code to get it to work again, after all, the site still worked just fine on its old server it is still being hosted on.
This is what I believe happened:
I copied the site files over, hooked up a site and bindings to it in IIS, and then tried to run it.
I got errors, and was forced to modify file handler bindings, the .net framework version of the app pool, and install new server roles/features to get it to at least produce this error.
I then deleted everything in the folder and re-copied the site files and it started working again.
IIS must have modified my site files in some way that prevented the site from working, and restoring the original code fixed it.
I know this is a very specific set of circumstances, but hopefully if someone else has the same situation some day they can solve it in the same simple way that I did.
Related
We have two identical web servers, one for test, one for production. We just moved an asp.net site onto the production. We have several Telerik controls including a set of RadButtons using the style WebBlue. On the test server, these buttons are formatted with a border around them and a blue background. However, on the production server, the buttons showing without the border or background color. Using the developer console in Chrome, we can see the error is a 404 error for WebResource.axd. This seems to be a Telerik style sheet. We've checked and both sites have the same files. This includes the bin folder containing the Telerik references and the web.config with Telerik and WebResource defined. We even directly copied all the code from one server to another and still there's this missing reference to WebResource.axd. Searching online leads to suggestions like IIS is set up to handle axd files and the web.config being incorrect. I've checked and the handling and web.config are identical. I even saw a suggestion to manually create the axd file that I tried without success (I went to testsite.com/WebResource.axd, copied what came up--code for a stylesheet--into a file called WebResource.axd, and copied with to the live server). We put a ticket into Telerik and they answered something about problems transferring a site from asp.net to asp.net MVC (which is NOT something we're doing). We've responded telling them this isn't a part of our issue, but we're stuck waiting on them and need to get this site up. Our thoughts now are that something with Telerik is missing from the production server (something outside the project folder, like in a Program Files or Windows folder) or that something in IIS is preventing axd files from being used. Does anyone out there with Telerik in IIS recognize this problem? How do we resolve it?
Here is the test site where the buttons are rendered correctly:
Here is the production site where the buttons are not rendered correctly:
Here is the error we're getting the production site:
Here is the text of the error if that picture is too small:
Failed to load resource: the server responded with a status of 404 (Not Found)
https://productionserver.com/WebResource.axd?d=dQ7gIaUlai3Z6U6rB3cRtOju4Bf1ReI3NFQN1mDwBRI0Q8BgW2h0xmppfMvidQSupNjZstrIfis4ClWbr3HyGn8paOvGU-zyEe2WESslWKjab9mEEnnjb-TympWmJzzpblolb7WlI-6yfnyWTQfAcQ0r7_q2C0pbHfF8BVnib-I1&t=635416927080000000
Here is the handler mapping in IIS showing that axd files are set up:
Here are the sections of the web.config that refer to Telerik and the WebResource.axd file:
<httpHandlers>
<add path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4" validate="false" />
<add path="ChartImage.axd" type="Telerik.Web.UI.ChartHttpHandler" verb="*" validate="false" />
<add path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" validate="false" />
<add path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" validate="false" />
<add path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler" verb="*" validate="false" />
<add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" validate="false" />
</httpHandlers>
<handlers>
<remove name="ChartImage_axd" />
<add name="Telerik.Web.UI.WebResource" path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>
<add name="ChartImage_axd" path="ChartImage.axd" type="Telerik.Web.UI.ChartHttpHandler" verb="*" preCondition="integratedMode" />
<remove name="Telerik_Web_UI_SpellCheckHandler_axd" />
<add name="Telerik_Web_UI_SpellCheckHandler_axd" path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" preCondition="integratedMode" />
<remove name="Telerik_Web_UI_DialogHandler_aspx" />
<add name="Telerik_Web_UI_DialogHandler_aspx" path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode" />
<remove name="Telerik_RadUploadProgressHandler_ashx" />
<add name="Telerik_RadUploadProgressHandler_ashx" path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler" verb="*" preCondition="integratedMode" />
<remove name="Telerik_Web_UI_WebResource_axd" />
<add name="Telerik_Web_UI_WebResource_axd" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" preCondition="integratedMode" />
</handlers>
* Update 1 *
Found some more information that might be useful. The line that references WebResource.axd is:
<link class='Telerik_stylesheet' type='text/css' rel='stylesheet' href='/WebResource.axd?d=oX7CVk8ieCqIm63GoqTn4pmChsM38l8-CqErNwBJK8bndDqbHfRL40riATcdts1t9WiNUwUdjINvesIa4uZisbBNhlldez1zIrFgnbzURY14adI59cmhQIUPb-zfBWhYQZrZZY8a1gGIfBfyuWSR6w2&t=635416927080000000' /><link class='Telerik_stylesheet' type='text/css' rel='stylesheet' href='/WebResource.axd?d=dQ7gIaUlai3Z6U6rB3cRtOju4Bf1ReI3NFQN1mDwBRI0Q8BgW2h0xmppfMvidQSupNjZstrIfis4ClWbr3HyGn8paOvGU-zyEe2WESslWKjab9mEEnnjb-TympWmJzzpblolb7WlI-6yfnyWTQfAcQ0r7_q2C0pbHfF8BVnib-I1&t=635416927080000000' />
On the test site (where it's working) it references http://testsite.com/WebResource.axd....
On the production site, this is where the 404 error comes in.
I'm trying to launch my web application (asp.net MVC) with debugging mode using Browser Link To Enable Edit Operations during Browser
but actually when i try to do this (Browser Link Not Working and it ask me to register the page inspector in the Web.Config)
Edit
and when i add the following to web.config nothing Happens
<add key="VisualStudioDesignTime:Enabled" value="true" />
<add key="PageInspector:ServerCodeMappingSupport" value="Enabled"/>
still i can't see that any browser connect through Browser Link
with knowledge that I Have Enabled debug=true in web.config
<compilation debug="true" targetFramework="4.6" />
and knowing that i have uninstall web essentials Package
I found this post very useful.
<system.webServer>
<handlers>
<add name="Browser Link for HTML" path="*.html" verb="*"
type="System.Web.StaticFileHandler, System.Web, Version=4.0.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
resourceType="File" preCondition="integratedMode" />
</handlers>
<modules runAllManagedModulesForAllRequests="true" />
</system.webServer>
Take care in that the <modules> element might already exist.
Add the following in your web.config:
<appSettings>
<add key="VisualStudioDesignTime:Enabled" value="true" />
<add key="PageInspector:ServerCodeMappingSupport" value="Enabled"/>
</appSettings>
I have a handler, on runtime it create a watermark on images from a specific folder. The problem is that it worked, but now it doesn't.
All that I did was to changed the hosting.
My web.config looks like this:
<handler>
<add verb="*" name="ImageWatermarkHandler" type="ImageWatermarkHandler"
path="Pics/*.jpg,Pics/*.png" modules="IsapiModule"
scriptProcessor="C:\Windows\Microsoft.NET\Framework64\v2.0.50727\aspnet_isapi.dll"
resourceType="Unspecified" preCondition="integratedMode" />
</handler>
Can you please help me?
Under IIS 7, you have to specify custom http handlers and modules under the configuration/system.webServer/handlers element of your web.config (unlike older IIS versions, where the element is configuration/system.web/httpHandlers).
There's difference between integrated mode (you only need the handlers part) and classic mode(you need both handlers and httpHandlers). For details see the MSDN entry
Edit: At first I haven't noticed the precondition for integrated mode, could it be that the new hosting runs your app in classic mode?
your config file should look like this,
<configuration>
<system.web>
<httpHandlers>
<add verb="*" path="Pics/*.jpg,Pics/*.png" type="ImageWatermarkHandler"/>
</httpHandlers>
</system.web>
<system.webServer>
<handlers>
<add verb="*" path="Pics/*.jpg,Pics/*.png" name="ImageWatermarkHandler" type="ImageWatermarkHandler"/>
</handlers>
<validation validateIntegratedModeConfiguration="false"/>
</system.webServer>
</configuration>
for more information,
http://msdn.microsoft.com/en-us/library/bb515343.aspx
Please help with HttpHandler
There is a HttpHandler that handles links to mysite.ru.
Registered in Web.Config as follows:
<configuration>
<system.web>
<httpHandlers>
<add verb="*" path="mysite.ru" type="App_Code.SyncHttpHandler"/>
</httpHandlers>
</system.web>
</configuration>
Now through the Handler open only references of the form:
mysite.ru
mysite.ru/struct/
mysite.ru/articles/
How to make the handler to intercept and treatment on the links of the form:
mysite.ru/files/images/img.jpg
mysite.ru/files/scripts/script.js
If I write so that you can run any links, including SyncHttpHandler/Google.ru.
And I need to be able to run only links a specific site.
<add verb="*" path="mysite.ru/*.*" type="App_Code.SyncHttpHandler"/> don't work
<add verb="*" path="*.*" type="App_Code.SyncHttpHandler"/> open any links
<httpHandlers>
<add verb="*" path="*.js" validate="false" type="SyncHttpHandler" />
<add verb="*" path="*.jpg" validate="false" type="SyncHttpHandler" />
</httpHandlers>
you can use this.
Typically, IIS process all static files by its own static file handler. So you need to first configure your IIS to pass all files (extensions) under this path to ASP.NET run-time. Exact steps (although similar) will depend upon IIS version - for example, see here for IIS 6.
Next part would be making sure that ASP.NET runtime passes all those requests to your handler. As such, I think that your config should work but if it doesn't then try using wild-cards. For example,
<add verb="*" path="mysite.ru/*.*" type="App_Code.SyncHttpHandler"/>
or perhaps,
<location path="mysite.ru" >
<system.web>
<add verb="*" path="*.*" type="App_Code.SyncHttpHandler"/>
</system.web>
</location>
In my ASP.Net 1.1 application, i've added the following to my Web.Config (within the System.Web tag section):
<httpHandlers>
<add verb="*" path="*.bcn" type="Internet2008.Beacon.BeaconHandler, Internet2008" />
</httpHandlers>
This works fine, and the HTTPHandler kicks in for files of type .bcn, and does its thing.. however for some reason all ASMX files stop working. Any idea why this would be the case?
Cheers
Greg
I got it... CQ you were on the right track.. i did need to add the .asmx handler again, but the .net 1.1 specific one. Final code is as follows:
<httpHandlers>
<add verb="*" path="*.bcn" type="Internet2008.Beacon.BeaconHandler, Internet2008" validate="false" />
<add verb="*" path="*.asmx" type="System.Web.Services.Protocols.WebServiceHandlerFactory, System.Web.Services, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" validate="false"/>
</httpHandlers>
I hope there's no other file types that are not getting handled properly because of this declaration. :|
Thanks for the help
greg
It sounds like it as an inherant <clear /> in it although I don't know if I've seen this behaviour before, you could just add the general handler back, let me find you the code.
<add verb="*" path="*.asmx" type="System.Web.Services.Protocols.WebServiceHandlerFactory, System.Web.Services" validate="false">
I think thats the right element, give it a shot.
EDIT: That is odd, I don't have a copy of 2003 on this machine so I can't open a 1.1 but I thought that was the right declaration. You could try adding validate="false" into each element and see if that makes a difference.