/******************************************* DHTML Ad Box (By Matt Gabbert at http://www.nolag.com)* Visit http://www.dynamicdrive.com/ for full script* This notice must stay intact for use******************************************/
adTime=19;  // seconds ad reminder is shownchanceAd=1; // ad will be shown 1 in X times (put 1 for everytime)

// @name      Slowly Fade// @version   0.88// @author    Richard D. LeCour// @namespace http://www.richardsramblings.com/?p=486var opacity = 96; // Avoid starting at 100% due to Mozilla bug
var Unopacity = 5; // Avoid starting at 100% due to Mozilla bugvar slowly = {	fade : function (id) {		this.fadeLoop(id, opacity);	},
	InitFade : function() {
		var o = document.getElementById('sponsorAdDiv');
	slowly.setstartOpacity(o, 0);	
	},
	Unfade : function (id) {
		var o = document.getElementById(id);
		slowly.setstartOpacity(o, 0);
		o.style.visibility = "visible";
		this.fadeUnLoop(id, Unopacity);	},	fadeLoop : function (id, opacity) {		var o = document.getElementById(id);		if (opacity >= 5) {			slowly.setOpacity(o, opacity);			opacity -= 4;			window.setTimeout("slowly.fadeLoop('" + id + "', " + opacity + ")", 50);		} else {			o.style.display = "none";		}	},
	fadeUnLoop : function (id, Unopacity) {		var o = document.getElementById(id);		if (Unopacity >= 5) {			slowly.setOpacity(o, Unopacity);			Unopacity += 4;			window.setTimeout("slowly.fadeUnLoop('" + id + "', " + Unopacity + ")", 50);		} else {			o.style.display = "block";		}	},	setOpacity : function (o, opacity) {		o.style.filter = "alpha(style=0,opacity:" + opacity + ")";	// IE		o.style.KHTMLOpacity = opacity / 100;				// Konqueror		o.style.MozOpacity = opacity / 100;					// Mozilla (old)		o.style.opacity = opacity / 100;					// Mozilla (new)	},
	setstartOpacity : function (o, opacity) {		o.style.filter = "alpha(style=0,opacity:" + opacity + ")";	// IE		o.style.KHTMLOpacity = opacity / 100;				// Konqueror		o.style.MozOpacity = opacity / 100;					// Mozilla (old)		o.style.opacity = opacity / 100;					// Mozilla (new)	}}

function initFade() {
	slowhigh('sponsorAdDiv');
//slowly.Unfade('sponsorAdDiv');
showAd();	
}
var ns=(document.layers);var ie=(document.all);var w3=(document.getElementById && !ie);var calunit=ns? "" : "px"adCount=0;function initAd(){	if(!ns && !ie && !w3) return;	if(ie)		adDiv=eval('document.all.sponsorAdDiv.style');	else if(ns)	adDiv=eval('document.layers["sponsorAdDiv"]');	else if(w3)	adDiv=eval('document.getElementById("sponsorAdDiv").style');	//randAd=Math.ceil(Math.random()*chanceAd);       // if (ie||w3)      // adDiv.visibility="visible";       //else        //adDiv.visibility ="show";
	slowly.Unfade('sponsorAdDiv');	//if(randAd==1) showAd();
	showAd();}function showAd(){if(adCount<adTime*10){adCount+=1;	/*if (ie){documentWidth  =truebody().offsetWidth/2+truebody().scrollLeft-20;	documentHeight =truebody().offsetHeight/2+truebody().scrollTop-20;}		else if (ns){documentWidth=window.innerWidth/2+window.pageXOffset-20;	documentHeight=window.innerHeight/2+window.pageYOffset-20;} 	else if (w3){documentWidth=self.innerWidth/2+window.pageXOffset-20;	documentHeight=self.innerHeight/2+window.pageYOffset-20;} 
	//adDiv.left=documentWidth-500+calunit;
	adDiv.left=280+calunit;
	adDiv.top =710+calunit;*/	setTimeout("showAd()",100);
	}
	else {
		closeAd();
	}}function closeAd(){//if (ie||w3)//adDiv.display="none";//else//adDiv.visibility ="hide";
slowly.fade('sponsorAdDiv');}function truebody(){return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body }


/************************************************ Gradual Highlight image script- � Dynamic Drive DHTML code library (www.dynamicdrive.com)* This notice MUST stay intact for legal use* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code***********************************************/var baseopacity=5function slowhigh(which2){
	var which2 = document.getElementById(which2);imgobj=which2browserdetect=which2.filters? "ie" : typeof which2.style.MozOpacity=="string"? "mozilla" : ""instantset(baseopacity)highlighting=setInterval("gradualfade(imgobj)",100)}function slowlow(which2){
cleartimer()instantset(baseopacity)}function instantset(degree){if (browserdetect=="mozilla")imgobj.style.MozOpacity=degree/100else if (browserdetect=="ie")imgobj.filters.alpha.opacity=degree}function cleartimer(){if (window.highlighting) clearInterval(highlighting)}function gradualfade(cur2){if (browserdetect=="mozilla" && cur2.style.MozOpacity<1)cur2.style.MozOpacity=Math.min(parseFloat(cur2.style.MozOpacity)+0.1, 0.99)else if (browserdetect=="ie" && cur2.filters.alpha.opacity<100)cur2.filters.alpha.opacity+=10else if (window.highlighting)clearInterval(highlighting)}

