Hello. I am looking at the following tutorial:
<img id="myimage" onclick="changeImage()"
src="pic_bulboff.gif" width="100" height="180">
<p>Click the light bulb to turn on/off the light</p>
What I don't understand is this line:
Where does "myimage" come from? Is "myimage" the name of a file? Is "myimage" the name of an object that I have to define somewhere? I assume that "pic_bulboff.gif" is the name of a file that should be kept in the same directory as the web page.
However, I would think the tutorial would do a better job of explaining where all these things come from. Anyone know of a better tutorial?
I am an idiot. Never mind.
I missed the definition right under the script. Duh!
How do I delete this thread?
... and the [code][/code] tags
Originally Posted by monkeys4freedom
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)