
// catches error and hides it, for IE in particular
function catchError(errType, errURL, errLine) {
	window.status = " ";
	return true;
}

	window.onerror = catchError;

	var clickmessage="Images are copy protected.";

	
	function disableclick(e) {
	
		/* find mouse position */

		var posx = 0;
		var posy = 0;
		if (!e) var e = window.event;
		
		
		if (e.pageX || e.pageY) {
			posx = e.pageX;
			posy = e.pageY;
			
		}
		else if (e.clientX || e.clientY) {
			posx = e.clientX + document.body.scrollLeft
				+ document.documentElement.scrollLeft;
			posy = e.clientY + document.body.scrollTop
				+ document.documentElement.scrollTop;
		}

		/* end of find mouse position */
		
		
		if( document.all ) {
			if( event.button==2 || event.button==3 ) {
				if( event.srcElement.tagName=="IMG" ) {
					
					alert(clickmessage);
					return false;
				}
			}
		}
		
		else if( document.layers ) {
			if( e.which == 3 ) {
				
				var move = document.getElementById("movable");
				move.style.left = (posx).toString()+"px";
				move.style.top = (posy).toString()+"px";
				return false;
				
			}
		}
		
		else if( document.getElementById ) {
			if( e.which==3 && e.target.tagName=="IMG" ) {
				
				var move = document.getElementById("movable");
				move.style.left = (posx).toString()+"px";
				move.style.top = (posy).toString()+"px";
				return false;
				
			}
		}
	
	}
	
	function associateimages() {
		for( i=0; i<document.images.length; i++ ){
			document.images[i].onmousedown=disableclick;
		}
		
	}
	
	
	if ( document.all ){
		document.onmousedown=disableclick;
	}
	else if( document.getElementById ){
		document.onmouseup=disableclick;
		
	}
	else if( document.layers ){
		associateimages();
	
	}
	

	
