editor adds host name to url in chrome

2 posts, 0 answers
  1. Dmitry
    Dmitry avatar
    1 posts
    Member since:
    Sep 2011

    Posted 13 Sep 2011 Link to this post

    Steps to reproduce :
    1. Open "Chrome" browser(I was not able to reproduce this behavior on IE and Firefox)
    2. Go to the  following link :"http://demos.telerik.com/aspnet-ajax/editor/examples/contentfilters/defaultcs.aspx"
    3. Select the "HTML" tab in editor 
    4. Paste following snippet into editor:  <div style="background-image: url(/~/image/picture.jpg);">text</div>
    5. Select the "Design" tab and then again select "HTML" tab

    As a result you will have the following:
    <DIV STYLE="BACKGROUND-IMAGE: URL(HTTP://DEMOS.TELERIK.COM/~/IMAGE/PICTURE.JPG);">TEXT</DIV>

    Editor adds the host name to url.

    Why after switching between tabs("Design" and "HTML") the host name was added to the url , and how can I prevent such a behavior? 
  2. Rumen
    Admin
    Rumen avatar
    13750 posts

    Posted 14 Sep 2011 Link to this post

    Hi Dmitry,

    Could you please disable the ConvertToXhtml filter and test again:

    RadEditor1.DisableFilter(Telerik.Web.UI.EditorFilters.ConvertToXhtml);

    Note that the tilde symbol is resolved in ASP.NET only and this path is invalid in the web.
    All the best,
    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
Back to Top