html - Difference between adding <![CDATA[ in page source v/s dynamically using javascript -


is there difference between --

<![cdata[ // content of javascript goes here ]]> 
  1. adding part of html response server v/s
  2. adding dynamically after page load using javascript (lets $('body').append(/cdata_goes_here/))

main question here whether cdata needs available part of page source or not?

leaving aside general issues adding content using js, cdata doesn't make difference.

it renders in xhtml document , gets parsed comment in html document.


Comments

Popular posts from this blog

javascript - Google App Script ContentService downloadAsFile not working -

javascript - Function overwritting -

c# - Exception when attempting to modify Dictionary -