// JavaScript Document
// Copyright 1996, Infohiway, Inc. (http://www.infohiway.com)
// Courtesy of SimplytheBest.net - http://simplythebest.net/scripts/

function adArray() {
 for (i=0; i*2<adArray.arguments.length; i++) {
  this[i] = new Object();
  this[i].src = adArray.arguments[i*2];
  this[i].href = adArray.arguments[i*2+1];
 }
 this.length = i;
}
function getAdNum() {
 dat = new Date();
 dat = (dat.getTime()+"").charAt(8);
 if (dat.length == 1)
  ad_num = dat%ads.length;
 else
  ad_num = 0;
 return ad_num;
}
var ads = new adArray(
"images/mpfire.jpg","http://www.melroseparkfire.com",
"images/pmc.jpg","http://www.principalmfg.com",
"images/peerless.jpg","http://www.peerlessindustries.com",
"images/paintercon30.jpg","http://www.paintersdc30.com/home.html",
"images/winston.jpg","http://www.newmarkmerrill.com/index.cfm?tdc=dsp&page=property_detail&pid=73",
"images/delgaldo.jpg","http://www.dlglawgroup.com",
"images/dartmouth.jpg","http://www.dartmouthservices.com",
"images/chicagotrailer.jpg","http://chicagotrailerpool.com");
var ad_num = getAdNum(); 
document.write('<CENTER><TABLE CELLPADDING=0 CELLSPACING=1 BORDER=0><TR><TD '
+'</FONT></TD><TR></TR><TD><A HREF="'+ads[ad_num].href+'" TARGET=_BLANK><IMG SRC="'+ads[ad_num].src+'" '
+'WIDTH="300" HEIGHT="200" BORDER=1 name=js_ad></A></TD></TR></TABLE></CENTER>');
link_num = document.links.length-1;
function rotateSponsor() {
 if (document.images) {
  ad_num = (ad_num+1)%ads.length;
  document.js_ad.src = ads[ad_num].src;
  document.links[link_num].href = ads[ad_num].href;
  setTimeout("rotateSponsor()",7000);
 }
}
setTimeout("rotateSponsor()",7000);
