function addEvent(obj, evType, fn){
	if (obj.addEventListener){
		obj.addEventListener(evType, fn, false);
	return true;
	}
	else if (obj.attachEvent){
		var r = obj.attachEvent("on"+evType, fn);
		return r;
	}
	else{
   		return false;
 	}
}

(function(){
 /*Use Object Detection to detect IE6*/
	var  m = document.uniqueID /*IE*/
	&& document.compatMode  /*>=IE6*/
	&& !window.XMLHttpRequest /*<=IE6*/
	&& document.execCommand;
	try{
		if(!!m){
			m("BackgroundImageCache", false, true) /* = IE6 only */ 
		}
	}
	catch(oh){};
})();

function jsemail(email) {
	for(i=email.length-1; i>=0; i--)
		document.write(email.charAt(i));
}

function jsemail(email) {
	for(i=email.length-1; i>=0; i--)
		document.write(email.charAt(i));
}

function jsemaillink(email, link) {
	document.write('<a href="'+link+'">');
	for(i=email.length-1; i>=0; i--)
		document.write(email.charAt(i));
	document.write('</a>');
}

function jsmailto(email, cim) {
	document.write('<a href="');
	for(i=email.length-1; i>=0; i--)
		document.write(email.charAt(i));
	document.write('">'+cim+'</a>');
}

function vidstat(vid) {
	var xmlHttpReq = false;
	if (window.XMLHttpRequest)
		xmlHttpReq = new XMLHttpRequest();
	// IE
	else if (window.ActiveXObject)
		xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
	xmlHttpReq.open("POST", "vidstat.php", true);
	xmlHttpReq.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
	xmlHttpReq.onreadystatechange = function() {
		if (xmlHttpReq.readyState==4) {
			if (xmlHttpReq.status==200) {}
        	}
	}
	xmlHttpReq.send("vid="+vid);
}
vidt=[];
function getUpdate(typ,pr1,pr2,swf) {
	if (vidt[swf]==undefined) {
		vidt[swf]=[];
		vidt[swf]['send']=0;
	}
	if (typ=='load' && pr1==0 && vidt[swf]['send']==0) {
		vidt[swf]['send']=1;
		var s=swf.split('|');
		vidstat(s[0]);
	}
}