Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Tarunjit 103 posts 146 karma points
    Feb 26, 2015 @ 13:25
    Tarunjit
    0

    Issue While Saving HTML Tags In Source Code Edtor

    Hi All,

    We are facing issues while trying save html code in the property of our page. This property is of type Rich Text Box Editor. We are saving it using Source Code option available in the toolbar of the rich text box editor. Just for your information we are using Umbraco 7.2.1 version.

    Here is the source code we are trying to save :-

    <a href="#" onclick="$('#pru-video').attr('src','//www.viddler.com/embed/42e09c7c/?f=1&offset=0&autoplay=t&player=full&secret=69229221&disablebranding=0&view_secret=74219692')">

        <div>

            <img src="../img/VideoThumb_BillChee.jpg" />

            <section>Memories of My First Sale</section>

            <br>

            <b>Bill Chee President,</b><br />

            and Agents

        </div>

    </a>

    After saving this code when we again we view it on source code editor and find that Umbraco remove most of the above code and save it as

    <div><img src="/img/VideoThumb_BillChee.jpg" alt="" />  Memories of My First Sale<br /> Bill Chee President,<br /> and Agents</div>

    Also there is one more problem with another code snippet :

    <h1><font>See What </font>Our Agents Have to Say About Life at Locations</h1>

    Above code snippet got saved as

    <h1>See What Our Agents Have to Say About Life at Locations</h1>

    Now this time <font> tag got removed. Not sure why this issue is coming.

    Can any one please help us on this? We are really struck.

    Regards

    Tarunjit Singh

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Feb 26, 2015 @ 14:06
    Jan Skovgaard
    0

    Hi Tarunjit

    Is there any specific reason why you try to store custom code in the rich text editor? Could there be another way around it perhaps?

    Perhaps you should have a look in the /config/TidyMceConfig.config file and see if you can modify it to allow more tags...you should be able to simply put * in the CDATA section of allowed content.

    But you really should not be using the tag - It's deprecated for a long time ago btw.

    Hope this helps.

    /Jan

Please Sign in or register to post replies

Write your reply to:

Draft