jquery - W3C Validation - Script Tag - Javascript or Something else? -
i'm getting bunch of errors in w3c validation because script tag missing type attribute. have 1 left on i'm not confident with
my code doesn't validate:
<script> !window.jquery && document.write('<script src="/jquery-1.4.3.min.js"><\/script>'); </script>
i've changed to:
<script type="text/javascript"> !window.jquery && document.write('<script src="/jquery-1.4.3.min.js"><\/script>'); </script>
i've read jquery framework in javascript, i'm assuming right above, there different 'type' utilize jquery?
thans!
if using doctype html4/xhtml, type attribute required.
but if using doctype html5, it's not required.
more : w3c scripts
javascript jquery w3c-validation
No comments:
Post a Comment