JavaScript/JavaScript within HTML: Difference between revisions

[checked revision][checked revision]
Content deleted Content added
mNo edit summary
Line 57:
The last line of the script, "<code>// --&gt;</code>", is a one line JavaScript comment that prevents the HTML end comment tag "<code>--&gt;</code>" from being interpreted as JavaScript.
 
The use of comment markers is rarely required nowadays, as the browsers that do not recognise the {{HTML:element|script}} element are virtually non-existent. These early browsers were Mosaic, Netscape 1, and Internet Explorer 2. From Netscape 2.0 in December 1995 and Internet Explorer 3.0 in August 1996. Those browsers were able to interpret JavaScript.<ref>[[w:JavaScript#History and naming]]</ref> Any modern browser that doesn't support JavaScript, recognizeswill still recognize the &lt;script&gt; tag and does not display it to the user.
 
=== Inline XHTML JavaScript ===