/*
regex = new RegExp("fun/index.php", "i");
if(document.referrer.match(regex)){
	openFullWin();
}
*/
	function openWindow () {
		var linkedUri = openSlWindow.arguments[0];
		 if(screen.width<1024){
			 alert("ディスプレイサイズを 1024 x 768 以上でご覧ください。");
		 }
		 var winPopup = window.open(linkedUri,"planetPOTATO","width=1014,height=710,resizable=yes,scrollbars=yes,menubar=yes,location=yes");
	}

function openSlWindow (url) {
	var mac = navigator.platform.indexOf("Mac")>=0; // MAC?
	var ie = navigator.appVersion.indexOf("MSIE")>=0; // IE?
	var ms = navigator.appVersion.indexOf("MSIE");
	var ie4 = (ms>0) && (parseInt(navigator.appVersion.substring(ms+5, ms+6)) >= 4);
	var nesc = navigator.appName.lastIndexOf("Netscape");
	var nesc4 = (nesc >= 0) && (parseInt(navigator.appVersion.substring(0,2)) >= 4);
	var open_url=url;
	if(screen.width<1024){
		alert( "画面解像度　1024 X 768 以上のディスプレイでご覧ください" ); 
	}else{
		if(mac){
			if(ie){ // MAC IE
			nextWindow = window.open(open_url,"fullScr","alwaysLowered=0,alwaysRaised=0,channelmode=0,dependent=1,directories=0,fullscreen=1,hotkeys=1,location=0,menubar=0,resizable=0,scrollbars=0,status=0,titlebar=0,toolbar=0,z-lock=0,screenX=0,screeny=0,left=0,top=0"); 
			nextWindow.resizeTo(screen.availWidth,screen.availHeight); 
			nextWindow.focus();
			}else{ // 
				nextWindow=window.open("","full","scrollbars=0,resizable=0,width=" + (screen.availWidth) +",height=" + (screen.availHeight-20)); 
				nextWindow.moveTo(0,0); 
				nextWindow.location.href=open_url; 
				nextWindow.focus();
			}
		}else{
			if(screen.width==1024){
				nextWindow=window.open(open_url,"screen","fullscreen=yes");
				nextWindow.focus();
			}else{
				wh = "width="+screen.availWidth +",height="+screen.availHeight+",resizable=yes,scrollbars=yes,location=no,menubar=no";
				var nextWindow= window.open(open_url,"nextWindow",wh);
				nextWindow.focus();
			}
		}
	}
}
