scW = screen.availWidth;					//スクリーンの有効領域幅
scH = screen.availHeight;					//スクリーンの有効領域高さ
np		= navigator.platform;				//ユーザーのプラットフォーム取得

//choose css file for mac or win
function chngCss(dir,name) {
	pass	= "";								//カレントドキュメントのディレクトリ設定用

	for (i = 1; i <= dir; i++)
		pass += "../";

	if (np.indexOf("Mac") >= 0) {
		document.write ('<link rel="StyleSheet" href="' + pass + name + '_mac.css" type="text/css" />');
	}
	else {
		document.write ('<link rel="StyleSheet" href="' + pass + name + '_win.css" type="text/css" />');
	}

}



//任意 window オープン
function openGeneWin(theURL,name,w,h,resize,scrll) {
	geneWin = name;

        theURL = 'http://ameblo.jp/yuumi-ag/';
	
	resize = 'yes';
	scrll = 'yes';
	//ウィンドウサイズ
	w = scW*w;
	h = scH*h;
	
	features = "width=" + w +",height=" + h +",menubar=yes,toolbar=yes,resizable=" + resize + ",scrollbars=" + scrll;
	geneWin = window.open(theURL,name,features);
	geneWin.focus();
}
//任意 window オープン
function openGeneWin1(theURL,name,w,h,resize,scrll) {
	geneWin = name;
	
	//ウィンドウサイズ
	//w = scW*w;
	//h = scH*h;
	
	features = "width=" + w +",height=" + h +",resizable=" + resize + ",scrollbars=" + scrll;
	geneWin = window.open(theURL,name,features);
	geneWin.focus();
}
//コピーライト表記
function copyright(dir) {
	pass	= "";								//カレントドキュメントのディレクトリ設定用

	for (i = 1; i <= dir; i++)
		pass += "../";

	prop = "JavaScript:openGeneWin('" + pass +"thanks.html','thanksWin','340','500','no','auto');";

	document.write ('copyright (c) A g a p e co.,ltd. All rights reserved 2006');
}

//スペシャルサンクス
function spsthanks(dir) {
	pass	= "";								//カレントドキュメントのディレクトリ設定用

	for (i = 1; i <= dir; i++)
		pass += "../";

	prop = "JavaScript:openGeneWin1('" + pass +"thanks.html','thanksWin','340','500','no','auto');";

	document.write ('<a href="' + prop + '" class="textgray">spesial thanks!</a>');
}

//スワップイメージ
function imgChange(name,url) {
	document.images[name].src = url;
}
