Hi Trevor,
JavaScript is not HTML, but a scripting language, so while, yes, the
JavaScript you posted is certainly a routine, it is not HTML. It can
be used in conjunction with HTML, just like CSS, which is also not
HTML. HTML includes attributes and an object model (DOM) that can be
used by JavaScript (or other scripting languages). However,
JavaScript can be used outside of HTML as well, and is, in fact, a
completely different technology.
I understood perfectly what the OP meant by what he said. I also saw
that his specific question had been answered quite well by Ronx and
Kathleen. My intent was to help him understand the difference between
markup, which is static, and process, which is dynamic. Understanding
this difference is essential if one intends to do anything dynamic
with a web page.
--
HTH,
Kevin Spencer
Microsoft MVP
Chicken Salad Shooter
http://unclechutney.blogspot.com
A man, a plan, a canal, a palindrome that has.. oh, never mind.