Keep Your Site Looking Fresh With Rotating Images

1.) You will need 6 graphics that are preferably the same size.

2.) Upload those images to a directory on your website.

3.) Place this piece of code below your opening body tag:

Code:
 <script language="JavaScript" type="text/javascript">
 // This script is free to use
 <!--
 // JavaScript to interpolate random images into a page.
 var ic = 6; // Number of alternative images
 var xoxo = new Array(ic); // Array to hold filenames

 xoxo[0] = "http://www.yourdomain.com/whereimagesare/image1.gif";
 xoxo[1] = "http://www.yourdomain.com/whereimagesare/image2.gif";
 xoxo[2] = "http://www.yourdomain.com/whereimagesare/image3.gif";
 xoxo[3] = "http://www.yourdomain.com/whereimagesare/image4.gif";
 xoxo[4] = "http://www.yourdomain.com/whereimagesare/image5.gif";
 xoxo[5] = "http://www.yourdomain.com/whereimagesare/image6.gif";

 function pickRandom(range) {
 if (Math.random)
 return Math.round(Math.random() * (range-1));
 else {
 var now = new Date();
 return (now.getTime() / 1000) % range;
 }
 }
 // Write out an IMG tag, using a randomly-chosen image name.
 var choice = pickRandom(ic);
 // -->
 </script>

4.) Place this piece of code where you’d like the graphics to show on yoru website: (change the width and height to your preference)

Code:
<SCRIPT LANGUAGE="JavaScript">
document.writeln('<TD'+'>
<IMG src="/'+xoxo[choice]+'" HEIGHT=184 WIDTH=120 BORDER=0 >
<'+'/TD>');</SCRIPT>
m121ban2





mp

Star Resell Our Services As Your Own
Basic Reseller
Pro Reseller
Reseller Login

register domain names
Domain Sales
.com $8.99 (Now-Sept)

dotme
NEW .ME
There’s a story inside each one of us, waiting to be told. Tell yours to the world with .ME -- the Top Level Domain that’s all about you!