Basic HTML version of Foils prepared 3 March 99

Foil 24 Example of Parameterized HTML

From Overview of JavaScript I -- Basic Web Scripting Language CPS616 Technologies of the Information Age -- Spring Semester 99. by Geoffrey C. Fox (Tom Scavo)

Some Parameterized HTML Links for Foil 24
<HTML><HEAD><TITLE>JavaScript Used to Parameterize HTML</HTML>
<SCRIPT LANGUAGE="JavaScript" > var imagewidth=600;// These could be changed by form var imagefile="npac.gif"; //input or some computation // based on size of window (available to JavaScript) </SCRIPT></HEAD>
<BODY> <h2>Plain old HTML of any type</h2> ...... <SCRIPT LANGUAGE="JavaScript" > document.writeln(`<imag align=top width=` + imagewidth + `src="' + imagefile +'" >'); </SCRIPT>
<b>And the beat goes on ...</b>
</BODY></HTML>
Note the horrible mix of ` (JavaScript) and " (HTML)
JavaScript Variables



© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Wed Mar 3 1999