Should I use CDATA in javascript? What difference does this make:

&lt;script type="text/javascript"&gt;
//&lt;![CDATA[ ...code


Compared to this

&lt;script type="text/javascript"&gt; ...code
You should not use XHTML 1.0 anymore ( which is where you would use CDATA ). What is even more important, you should no have javascript inside your html files. Instead you should include external files via &lt;script src="/my/js/file.js"&gt;&lt;/script&gt;.