"As it stands, all of the javascript files are sent in the head element, ...."
So, don't put the js in the head. Nothing in HTML4.01 (I don't know about HTML5) bars inclusion of your script(s) (or links to your script(s)) in the body of the html.
Adapted from http://w3schools.com/dhtml/tryit.asp?filename=trydhtml_intro, where it is included in the head... but cf, this mod:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/T +R/html4/strict.dtd"> <html> <head> <title>js test</title> </head> <body> <h1>Hello.</h1> <p> This is a para with a 1-char indent.</p> <script type="text/javascript"> document.write("Hello World!") </script> <script type="text/javascript"> cc=0; function changeimage() { if (cc==0) { cc=1; document.getElementById('myimage').src="bulbon.gif"; } else { cc=0; document.getElementById('myimage').src="bulboff.gif"; } } </script> <!-- does not pass strict for lack of an alt in the images --> <img id="myimage" onclick="changeimage()" src="bulboff.gif" alt="bulb" + width="100" height="180" /> <p>Click to turn on/off the light</p> </body> </html>
In reply to Re: Passing javascript last in CGI
by ww
in thread Passing javascript last in CGI
by ERasche
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |