Metachecker.net
|
TrafficChecker.net
|
RankChecker.net
Learn Java Script Today
|
Over 5000 Free Fonts
|
Tutorials
|
Javascript Forum
|
Other Javascript Resources
|
Cheat Sheet
JavaScript Basics
Inserting Javascript
Complete Tutorial
Advance DHTML Tutorial
Script archive
Advanced Tutorials
Alert Scripts
Animation
Audio
Background Effects
Banner Ads
Browser Window
Buttons
Button Forms
Calculcators
Calendars
Clocks & Dates
Cookies
Cursor Effects
DHMTL Games
DHTML Miscellaneous
Equivalents
Forms
Games
IE4+ Scripts
IE5+ Scripts
Image Effects
Image Miscellaneous
Links & Buttons
Math Related
Messages Miscellaneous
Miscellaneous
Mouse Tricks
Navigation
Page Details
Password Protection
Pulldown Menus
Random Stuff
Scrolling
Status Bar
Text Animation
User Detail
User Info
Window Control
Random Ads
When the page is loaded a random ad and link are generated.
Insert into <HEAD>
<script language="javascript"> <!-- function randadd0() { //create an array of add images var i = new Array(new Image(120,60), new Image(120,60), new Image(120,60)); i[0].src="intellimouse.gif"; i[1].src="simcity3k120x60anim.gif"; i[2].src="quicken99.gif"; // I use constants so it will be easy to change values if I put up new adds var INTELLIMOUSE="script589128_0_2.html#a"; var SIMCITY="script589128_0_2.html#b"; var QUICKEN="script589128_0_2.html#c"; //get a random number between 0 and the number of adds available var pictnum=Math.round(Math.random()*3)-1; while(pictnum<0 || pictnum>3) pictnum=Math.round(Math.random()*3)-1; //change the banner add picture document.link0.src=i[pictnum].src; //change the banner add link to match the picture if(pictnum==0) document.links[0].href=INTELLIMOUSE; else if(pictnum==1) document.links[0].href=SIMCITY; else if(pictnum==2) document.links[0].href=QUICKEN; } //--> </script>
Insert into <BODY>
<BODY onLoad="randadd0()"> <a href="index.htm"><IMG SRC="1.gif" BORDER=0 WIDTH=120 HEIGHT=60 NAME="link0" ALT="add banner"></a>
Other Options