I would like to see a (written) best practice of putting all javascript content into the
head of the
XHTML document.
Reason 1:
Moving all script into the head makes it easier to find and makes impossible bad (and
often non WCAG
compliant) practices such as attaching script to xml attributes.
It makes it less of a jungle.
Reason 2:
If we have no script in the body of any documents then users can implement filters which
remove any
script after the </head> tag. This would make script injection certifiably
impossible.
WDYT?
Caleb