// Created by jsbanners.pl, Sun Feb  5 05:01:58 2012

// time between refreshs of ad locations, to disable refreshs set to 0. In milliseconds, 1000 = 1 second
var refresh_time = 12000;

// ignore/skip this line 
var banners = new Array();

// banner list syntax: banners[x] = new banner(website_name, website_url, banner_url, show_until_date, target);  DATE FORMAT: dd/mm/yyyy
// be sure to increase x by 1 for each banner added!
// to make sure a banner is always rotating, just set the date far into the future, i.e. year 3000

banners[0] = new banner('Banner 0','/cgi-bin/store.cgi','http://sites.etotalhost.com/common/image/banners/YYY/toystore.gif','30/04/2019','content');
banners[1] = new banner('Banner 1','http://videos.globalfight.com','http://personals.manspank.us/common/image/banners/MSP/video_animated.gif','30/04/2019','_blank');
banners[2] = new banner('Banner 2','http://astore.amazon.com/one063-20','http://personals.manspank.us/common/image/banners/MSP/manspank_bookstore.jpg','30/04/2019','_blank');
banners[3] = new banner('Banner 3','http://www.thedungeon.us','http://personals.manspank.us/common/image/banners/MSP/thedungeon.jpg','30/04/2019','_blank');
banners[4] = new banner('Banner 4','http://www.curious-men.com','http://personals.manspank.us/common/image/banners/MSP/curious-men.jpg','30/04/2019','_blank');
banners[5] = new banner('Banner 5','http://www.realmenhavehair.com','http://personals.manspank.us/common/image/banners/MSP/realmenhavehair.jpg','30/04/2019','_blank');
banners[6] = new banner('Banner 6','http://personals.personalmale.com','http://personals.manspank.us/common/image/banners/MSP/personalmale.jpg','30/04/2019','_blank');
banners[7] = new banner('Banner 7','http://personals.findgaydad.com','http://personals.manspank.us/common/image/banners/MSP/findgaydad_promo_button_468_60.gif','30/04/2019','_blank');

//         				There is no need to edit below here
///////////////////////////////////////////////////////////////////////////////////

var first_pass = 0;
var location_counter = 0;

function banner(name, url, image, date, target)
{
	this.name	= name;
	this.url	= url;
	this.image	= image;
	this.date	= date;
	this.target	= target;
	this.active = 1;
}

function show_banners()
{
	if (!first_pass++) {
		var html = '<div id="adLocation"></div>';
		document.write(html);
		window.setInterval(show_banners, refresh_time);
	}
	display_banners(location_counter);
	location_counter = ++location_counter % banners.length;
}

function display_banners(location)
{
	var bn = banners[location];
	
	var html 		= '<a href="' + bn.url + '" title="' + bn.name + '" target="' + bn.target +'"><img border="0" src="' + bn.image + '" alt="' + bn.name+ '" /></a>';
	
	var location_element = document.getElementById('adLocation');
	
	if(location_element == null)
	{
		logmsg('adLocation does not exist' + location);
	}
	else
	{
		location_element.innerHTML = html;
	}
}

//Sun Feb  5 05:01:58 2012

