Re: JavaScript Tutorial Question

by DScha97041(at)aol.com

 Date:  Fri, 24 Sep 1999 00:24:56 EDT
 To:  denise(at)nf.sympatico.ca,
hwg-basics(at)hwg.org
  todo: View Thread, Original

In a message dated 9/23/99 8:03:13 PM, denise(at)nf.sympatico.ca writes:

>What exactly does this line do?
> onMouseOver="temp=image1; image1=image2; image2=image3; image3=temp;
>document.the_image.src=image1;"
>onClick="document.brand_image.src=image1;">
>
When you put the mouse over the link(which starts as the monkey.gif) the
images will be rotated through temp to the next image. Then sets the 
displayed image to image1. Basically what happens that every time you put 
the mouse over the image it is changed to the next image.
When you click brand_image will be = to whatever image1 is equal to at the 
time.

Is that what happened in your tutorial?

>
>var temp = "";
>var image1 = 'thau.gif';
>var image2 = 'sky.gif';
>var image3 = 'monkey.gif';


Dick

HTML: hwg-basics mailing list archives, maintained by Webmasters @ IWA