for those who don't know the wonders of
the innerHTML tag attribute, below is an
introductory sample. The function 'println'
uses the innerHTML attribute of a span
tag to write text in a specific place on the
screen.
this code is from my solution to
assignment 9, which can be found at:
http://citweb.lanecc.edu/robintreem/133/a
ssign9/3_form.html
function println(value)
{
// 'output' is the ID of a span tag near the
bottom of this page
// innerHTML refers to all the HTML
between the start and end tags of 'output'
// [ += value ] means append new HTML
text to the end of output's innerHTML
output.innerHTML += value + "
";
}
the above function adds HTML text to the
span tag below:
{span id='output'}{!-- this is where println
puts text --}{/span}
note that id='output' could be put in any
other tag besides a {SPAN} tag, such as
a {TD}, a {P}, {h1}, {ol}, {option}, etc. --
almost any tag that has HTML or text
between it's start and end tags.
note also that in order to post to this
message board, i had to substitute the
left and right tag brackets with curly
brackets. just pretend they're tag
brackets.