Rad Editor - Anchor tag issue

2 posts, 0 answers
  1. Pranav
    Pranav avatar
    1 posts
    Member since:
    Jul 2016

    Posted 13 Jul Link to this post

    In body of Rad editor if i pasted the code below in HTML container -

    <a href="http://members.farmtoconsumer.org/donations/" target="_blank">
    <figure class="center-img">
    <img style="border: 0px solid currentColor; border-image: none; width: 100%; max-width: 303px !important;" alt="Donate Today!" src="https://media.mercola.com/assets/images/donate-today.jpg">
    <figcaption class="op-large op-center hide-figcap">
    <a href="http://members.farmtoconsumer.org/donations/" target="_blank">Click Here</a>
    </figcaption>
    </figure>
    </a>

    After this when i switch from HTML to design and then again back to HTML the code changes to below code -

    <a href="http://members.farmtoconsumer.org/donations/" target="_blank">
    </a><figure class="center-img"><a href="http://members.farmtoconsumer.org/donations/" target="_blank">
    <img style="border: 0px solid currentColor; border-image: none; width: 100%; max-width: 303px !important;" alt="Donate Today!" src="https://media.mercola.com/assets/images/donate-today.jpg">
    </a><figcaption class="op-large op-center hide-figcap"><a href="http://members.farmtoconsumer.org/donations/" target="_blank">
    </a><a href="http://members.farmtoconsumer.org/donations/" target="_blank">Click Here</a>
    </figcaption>
    </figure>

    Notice that the <a> tag was immediately closed. It seems like the editor updates the codes accordingly (some sort of auto-correcting html codes I guess). Is there any way we can avoid this or is this something that we cannot modify or any solution for this?

  2. Misho
    Admin
    Misho avatar
    129 posts

    Posted 15 Jul Link to this post

    Hello,

    This is the browsers' behavior that are modifying the HTML in this manner. This could be observed also on a page with simple editable div:
    http://dojo.telerik.com/@parvanov/enAZO
    Here is a video showing the result of the test:
    http://screencast.com/t/opxR4Wn9x

    Best Regards,
    Misho
    Telerik by Progress
    Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top