
	if (window.Event) {
		document.captureEvents(Event.MOUSEUP);   
	}

	function disableMenu(){  
		event.cancelBubble = true  
		event.returnValue = false;  
		return false;  
	}  
	
	function disableRightClick(e){  
		if (window.Event){  
			if (e.which == 2 || e.which == 3){  
				return false; 
			}
		}else  if (event.button == 2 || event.button == 3){  
				event.cancelBubble = true  
				event.returnValue = false;  
				return false;  
		}  
	}  
	
	function allowClick(){
		return true
	}
	
	function disableSelect(){
		if(event.srcElement.tagName != 'INPUT'){
			return false;
		}
	}
	
	document.onmousedown=disableSelect
	document.onclick=allowClick

	document.onselectstart=disableSelect;
	document.oncontextmenu = disableMenu;   
	document.onmousedown = disableRightClick;   
