143Re: [jslint] Re: body tag
- Aug 5, 20082008/8/5 Paul de Jong <riderpaul@...>:
> The issue I was referring to is that the body tag needs to beNot always, I have inline scripts that work just fine so long as the
> completely loaded before a DOM script runs,
parts of the DOM they are manipulating are ready & available.
> especially if you haveSeems reasonable to me that the body should be complete before you add to it.
> something like document.body.appendChild in your script.
> Having theHow complicated is <body
> script in the body means one needs to do complicated DOM checking to
> make sure the body is loaded before the script runs...or at least set
> a arbitrary delay in the hopes that the end of the body will get
> processed in that time.
> It seems weird to put the script tag inside the body tag, whenHey, if it works for you then go for it. So long as you don't care
> logically it should come after it. I was just wondering if there was
> some reason other then the one you stated.
> I have never encountered a problem putting the script tag after the
> body tag.
about your HTML being invalid according to the DTD, so it may break
unexpectedly in future browser versions. If you care so much, you can
also join the HTML 5 discussions and try to get it added to the spec.
What does any of this have to do with JSLint, though? Are you saying
that your inline script isn't being checked if it's not inside the
head or body tags?
- << Previous post in topic Next post in topic >>