Problem - Cute Editor adding <![CDATA[ in front of JQuery Code

Last post 05-21-2009, 2:31 PM by leadville. 2 replies.
Sort Posts: Previous Next
  •  05-15-2009, 11:29 AM 52195

    Problem - Cute Editor adding <![CDATA[ in front of JQuery Code

    Below is my original Code.  If I make any changes to the code below and click submit/post, Cute Editor adds <script type="text/javascript"><![CDATA[ and then finishes off with ]]></script>.  So basically after hitting submit it raps my JQuery code with the CDATA making it not work correctly.
     
    <script type="text/javascript">
    at_attach("attach_menu_p1", "attach_menu_c1", "hover", "y", "pointer");
    at_attach("attach_menu_p2", "attach_menu_c2", "hover", "y", "pointer");
    at_attach("attach_menu_p3", "attach_menu_c3", "hover", "y", "pointer");
    //at_attach("attach_menu_p4", "attach_menu_c4", "hover", "y", "pointer");
    at_attach("attach_menu_p5", "attach_menu_c5", "hover", "y", "pointer");
    //at_attach("attach_menu_p6", "attach_menu_c6", "hover", "y", "pointer");
    $(document).ready(function(){
    $("#attach_menu_c2").css("opacity","0.85");
    $("#attach_menu_c2").css("z-index","100000");
    $("#attach_menu_c3").css("opacity","0.85");
    $("#attach_menu_c3").css("z-index","100000");
    //$("#attach_menu_c4").css("opacity","0.85");
    //$("#attach_menu_c4").css("z-index","100000");
    $("#attach_menu_c5").css("opacity","0.85");
    $("#attach_menu_c5").css("z-index","100000");
    //$("#attach_menu_c6").css("opacity","0.85");
    //$("#attach_menu_c6").css("z-index","100000");
    });
    </script>
     
     Any way of turning this off?
     
  •  05-15-2009, 2:20 PM 52202 in reply to 52195

    Re: Problem - Cute Editor adding <![CDATA[ in front of JQuery Code

    Please use .Text property instead of XHTML property to extract the content from editor.
     
    XHTML pages don't validate unless you wrap javascript code in CDATA. . A CDATA section in XML/XHTML starts with the characters <![CDATA[ and ends with the characters ]]>.

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  05-21-2009, 2:31 PM 52404 in reply to 52202

    Re: Problem - Cute Editor adding <![CDATA[ in front of JQuery Code

    Adam,
     
    Just wanted to let you know your response worked perfectly.  Thanks a ton.
     
    Cheers
     
    Tom
View as RSS news feed in XML