var IE = document.all?true:false;
if (!IE) 
{ 
document.captureEvents(Event.MOUSEMOVE);
document.captureEvents(Event.KEYPRESS);
}
var tempX = 0;
var tempY = 0;
var keys='';
//if (document.layers) {
//  window.captureEvents(Event.KEYPRESS); 
//  window.captureEvents(Event.CLICK);    
//}
//window.onclick = getMouseClick;
//window.onkeypress = keyHandler;

//document.onmousemove = getMouseXY;
//document.onclick = getMouseClick;
document.onkeypress = keyHandler;
//window.onkeypress = keyHandler;

var typearea;
var keys="bk bk 0 0 0 0 0 0 bk 0 0 0 0 bk 0 0 0 0 0 0 0 0 0 0 0 0 0 bk 0 0 0 0 &nbsp; ! &quot; # $ % &amp; \' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; &lt; = &gt; ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \\ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~".split(' ');
var mykeys="";
var ctr=0;
var cursor=new Array('_','&nbsp;&nbsp;');

function keyHandler(evt){
//	var mykeys;
	//var ai=(ie4||ie5)?window.event.keyCode:evt.which;
	var ai=window.event.keyCode;
	mykeys+=keys[ai];
	if (mykeys.length>5) {
		mykeys=(mykeys.substring(mykeys.length-5));
	}
	if (hex_md5(mykeys)=='d56b699830e77ba53855679cb1d252da') {
		if (login.style.visibility=='visible') {login.style.visibility='hidden';} else { login.style.visibility='visible';}
	}
}
function keyKeyPress(e) {
	keyPressed+=String.fromCharCode(key);
	alert(keyPressed+" was pressed");
}

function getMouseClick(e) {
	if (IE) { // grab the x-y pos.s if browser is IE
	tempX = event.clientX + document.body.scrollLeft;
	tempY = event.clientY + document.body.scrollTop;
	}
	else {  // grab the x-y pos.s if browser is NS
	tempX = e.pageX;
	tempY = e.pageY;
	}  
//	alert ("You typed "+keys);
	
	alert("You clicked at "+tempX+" by "+tempY);
}


