spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

Developer News
Microsoft Shows Off Silverlight 4, IE9 Plans
Metasploit Expands Vulnerability Test Framework
HyperCard Reborn?

JavaScript Tip of the Week for May 27, 1996: Source Code: The Infamous 3.0 (Netscape Navigator)

Jump to source of:


Source code for The Amazing Dynamic Image:
/* This code is Copyright (c) 1996 Nick Heinle and Athenia Associates, 
 * all rights reserved. In order to receive the right to license this 
 * code for use on your site the original code must be copied from the
 * Web site webreference.com/javascript/. License is granted to user to 
 * reuse this code on their own Web site if and only if this entire copyright
 * notice is included. Code written by Nick Heinle of webreference.com.
 */

which_one = 0; 
function change() 
        {
                if (which_one == 0) 
                {               
                document.images[1].src = "fade.gif";
                which_one = 1;
                }
                else
                {
                document.images[1].src = "../../menus/jtotw.gif";
                which_one = 0;
                }
        }



Source code for How to Create Animations Using JavaScript:
/* This code is Copyright (c) 1996 Nick Heinle and Athenia Associates, 
 * all rights reserved. In order to receive the right to license this 
 * code for use on your site the original code must be copied from the
 * Web site webreference.com/javascript/. License is granted to user to 
 * reuse this code on their own Web site if and only if this entire copyright
 * notice is included. Code written by Nick Heinle of webreference.com.
 */

delay = 100;
imgNumber = 0;
totalimgNumber = 8;
anim = new Array();

for (i = 0; i < totalimgNumber; i++) {
anim[i] = new Image (239, 390);
anim[i].src = 'wave' + (i + 1) + '.gif';
} 

function Switch() {                
document.waveanim.src = anim[imgNumber].src;
imgNumber++;
        if(imgNumber >= totalimgNumber) imgNumber = 0;
}
                
function animate() {
Switch();
setTimeout("animate()", delay);
}

function slow() {
delay+=10;
if(delay > 4000) delay = 4000;
}
        
function fast() {
delay-=10;
if(delay < 0) delay = 0;
}

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Rolling Out Your Own HTML Application Version Control · HTML 5: Client-side Storage · Working with Ajax Server Extensions
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Wi-Fi Product Watch, November 2009 · Chip Market Recovering From '08 Collapse · Low-Cost Tools to Kickstart Your New Business