


function setHover(id, state) {
	
	if (document.getElementById) {
		var otherImage = document.getElementById(id);
		
		if (otherImage && typeof otherImage.className == 'string') {
			
			otherImage.className = (state ? 'hov' : '');
			// "I hate JavaScript hack"
			otherImage.style.color = (state ? '#ffffff' : '');
			//error(otherImage.style.color+'< id, class is being changed to '+otherImage.className);
		}
	}
}

function doVideo(data) {
		
	if(data == "") window.history.go(0);
	
	var specElem = document.getElementById('videoHolder');
	specElem.innerHTML = Url.decode(data);
	//error(data);

}





/* This script and many more are available free online at
The JavaScript Source!! http://javascript.internet.com
Created by: Justas | http://www.webtoolkit.info/ */
var Url = {

 	// public method for URL encoding
 	encode : function (string) {
 		 return escape(this._utf8_encode(string));
 	},

 	// public method for URL decoding
	 decode : function (string) {
 	 	return this._utf8_decode(unescape(string));
 	},

 	// private method for UTF-8 encoding
 	_utf8_encode : function (string) {
  		string = string.replace(/\r\n/g,"\n");
 	 	var utftext = "";

  		for (var n = 0; n < string.length; n++) {
   			var c = string.charCodeAt(n);
   			if (c < 128) {
    				utftext += String.fromCharCode(c);
 			} else if((c > 127) && (c < 2048)) {
  				utftext += String.fromCharCode((c >> 6) | 192);
  				utftext += String.fromCharCode((c & 63) | 128);
 			} else {
  				utftext += String.fromCharCode((c >> 12) | 224);
  				utftext += String.fromCharCode(((c >> 6) & 63) | 128);
 	 			utftext += String.fromCharCode((c & 63) | 128);
 			}
 	}

		return utftext;
	},

 	// private method for UTF-8 decoding
 	_utf8_decode : function (utftext) {
 		 var string = "";
 		 var i = 0;
 		 var c = c1 = c2 = 0;

	//	utftext.replace("+", " ");
		
  		while ( i < utftext.length ) {
  			 c = utftext.charCodeAt(i);
   			if (c < 128) {
    				string += String.fromCharCode(c);
    				i++;
  			 } else if((c > 191) && (c < 224)) {
 				   c2 = utftext.charCodeAt(i+1);
    				string += String.fromCharCode(((c & 31) << 6) | (c2 & 63));
    				i += 2;
  			 } else {
 				   c2 = utftext.charCodeAt(i+1);
    				c3 = utftext.charCodeAt(i+2);
    				string += String.fromCharCode(((c & 15) << 12) | ((c2 & 63) << 6) | (c3 & 63));
   				 i += 3;
 			  }
		  }
		return string;
	 }
}


function error(fm){
	el=document.getElementById("__wtframework");
	if(el){
		document.body.removeChild(el);
		//setTimeout(error(fm), 350);
		return;
		
	}
	var c=document.createElement("a");
	c.id="__wtframework";
	c.style.opacity="0.7";c.style.filter="alpha(opacity=70)";
	c.style.position="fixed";c.style.zIndex="9000";c.style.top="15px";
	c.style.right="20px";
	//c.style.width="auto";
	c.style.background="#000";
	c.style.styleFloat="right";
	c.style.padding="7px 10px";
	c.style.color="#fff";
	
	c.style.border="solid 2px #fff";
	c.style.textDecoration="none";
	c.style.textAlign="left";
	c.style.font="12px Lucida Grande,Helvetica,Tahoma";
	c.style.MozBorderRadius="5px";
	c.style.WebkitBorderRadius="5px";
	c.style.WebkitBoxShadow="0px 0px 20px #000";
	c.style.MozBoxShadow="0px 0px 20px #000";
	c.href="javascript:void(0)";
	document.body.appendChild(c);
	c.onclick=function(){document.body.removeChild(c)};
	
	c.innerHTML=unescape(fm.toString())
	//removeError();
};

function removeError() {
	el=document.getElementById("__wtframework");
	if(el){
		setTimeout("document.body.removeChild(el)", 900);
	
		return;
		
	}	
	
	
}