RadCodeBlock and CDATA

2 posts, 0 answers
  1. Thomas
    Thomas avatar
    143 posts
    Member since:
    Feb 2007

    Posted 17 Sep 2009 Link to this post

    I'm trying to track down some issues with invalid viewstate errors on my site. It is already the case that the site is using a specific machine key in the config file. One item noted on this post (http://bytes.com/topic/asp-net/answers/861764-invalid-viewstate-system-string-decryptstringwithiv) is that some of the script blocks are not wrapped in CDATA. In looking at the source for my site, I too notice that none of my blocks are wrapped in CDATA blocks which surprised me given that they are all wrapped in RadCodeBlocks.

    Is it the case that RadCodeBlocks do not automatically wrap their contents in CDATA blocks when the DOCTYPE is set to XHTML? Is there a setting on the RadCodeBlocks to have it do so?
  2. Dimo
    Admin
    Dimo avatar
    8333 posts

    Posted 18 Sep 2009 Link to this post

    Hi Thomas,

    The RadCodeBlock control does not render any content on its own and it does not modify the output of controls or scripts placed inside it. The purpose of RadCodeBlock is described here:

    http://www.telerik.com/help/aspnet-ajax/ajxradscriptblockradcodeblock.html

    If you want to have CDATA blocks, please add them manually.

    Regards,
    Dimo
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top