This is a migrated thread and some comments may be shown as answers.

RadEditor Image Path Defaulting to Wrong Value

4 Answers 147 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Tom
Top achievements
Rank 1
Tom asked on 01 Feb 2011, 09:45 PM
I am using RadEditor and the images that I place in the editor have absolute URLs.  According to what I've read (and what I want) the paths should be relative URLs. 

4 Answers, 1 is accepted

Sort by
0
Tom
Top achievements
Rank 1
answered on 02 Feb 2011, 04:22 PM
Can anyone explain this or please give me advice how to fix it.  I think the default behavior is being overridden, but none of the normal overrides have been implemented.
0
Rumen
Telerik team
answered on 04 Feb 2011, 12:47 PM
Hi Tom,

By default the images are inserted with relative paths through the Image Manager of RadEditor for ASP.NET AJAX. They will be inserted with absolute paths only when the MakeUrlsAbsolute content filter is enabled. This filter is disabled by default.

Please, note that RadEditor keeps the image and link paths of the loaded or pasted images and link tags. So if you paste / load an image with absolute src path it will remain as it is, e.g.

<img src="http://www.feedsocial.com/highslide/images/full-image.jpg" alt="product logo" />

If you load an image / link with relative path it will remain relative.

Only the paths of the inserted through the Image Manager and Link manager dialogs files are relative.

Kind regards,
Rumen
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Tom
Top achievements
Rank 1
answered on 04 Feb 2011, 01:30 PM
Thanks for you assistance, but your solution is either incorrect or you have to enable something to permit the solution you suggested.  Can you explain how, using the image manager, to load an image using a relative path?  It can't be done. 

If I paste in a relative path in the load image dialog, e.g., /images/image.jpg it won't work. It only allows me to browse and when I browse to the right folder and load the image it ends up in the final page with a absolute url, e.g., http://localhost/images/image.jpg. 
0
Rumen
Telerik team
answered on 09 Feb 2011, 05:04 PM
Hello Tom,

Where exactly do you check the src path of the image? It is enough to go to HTML mode and see whether the image has an absolute or relative path as shown in the following video: http://screencast.com/t/4yUNFhhi1.
The content displayed in HTML mode is this that the editor submits to the server and that will be saved in the database.

As I wrote earlier the default editor configuration is to insert images with relative paths. Can you please make sure that you use the latest version of RadEditor Q3 2010 SP2 (version 2010.3.1317)? If you use an older version upgrade to the latest one. If the problem is reproducible in the latest version, isolate it in a sample working project and send it for examination by opening a support ticket.

Best regards,
Rumen
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
Grid
Asked by
Tom
Top achievements
Rank 1
Answers by
Tom
Top achievements
Rank 1
Rumen
Telerik team
Share this question
or