function runSWF(src,w,h)
{
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0";
document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="'+codebase+'" width="'+w+'" height="'+h+'">\n');
document.write('<param name="movie" value="'+src+'" />\n');
document.write('<param name="quality" value="high" />\n');
document.write('<param name="wmode" value="transparent" />\n');
document.write('<embed src="'+src+'" quality="high" wmode="transparent" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="'+w+'" height="'+h+'"></embed>\n');
document.write('</object>\n');
}


function goToURL() { //v3.0
  var i, args=goToURL.arguments; document.returnValue = false;
  for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location='"+args[i+1]+"'");
}



function chgFsize(flg) {
	if(flg!="s" && flg!="m" && flg!="l" && flg!="sp") {
		flg="m";
	}
	str = $('fsstyle').href;
    fstr = str.match(".+/(.+?)\.[a-z]+$")[1];
    if (fstr!='') {
    	$('fsstyle').href=str.replace(fstr,"common_"+flg);
    }
	tm = new Date();
	tm.setTime(tm.getTime() + (365 * 1000 * 60 * 60 * 24));
	tm = tm.toGMTString();
	document.cookie = "fsize=" +flg+ ";path=/;expires=" + tm;
	$('fonts').className = "";
	$('fontm').className = "";
	$('fontl').className = "";
	$('fontsp').className = "";
	$('font'+flg).className="active";
}
function chgFcolor() {
	if($('fontC').className=="active") {
		$('fontC').className = "";
		flg = "";
	} else {
		$('fontC').className = "active";
		flg = 2;
	}
	//$('fscolor').href="/usr-data/template/odawara-synthetic/css/color"+flg+".css";
	str = $('fscolor').href;
    fstr = str.match(".+/(.+?)\.[a-z]+$")[1];
    if (fstr!='') {
    	$('fscolor').href=str.replace(fstr,"color"+flg);
    }
	
	tm = new Date();
	tm.setTime(tm.getTime() + (365 * 1000 * 60 * 60 * 24));
	tm = tm.toGMTString();
	document.cookie = "fcolor=" +flg+ ";path=/;expires=" + tm;
}

function enq_comp(){
	//文字数チェック(400文字)
	txt = document.page_enq.enq_comment.value;
	if (txt.length > 400) {
		alert("ご意見・ご感想等は400文字以内でご記入ください。");
		return false;
	} else {
		document.page_enq.submit();
		$('enq_area_inner').innerHTML = '<p style="border:none;">受付完了しました。</p>';
		return true;
	}
}

function wDate(ele) {
	var w = ["日","月","火","水","木","金","土"];
	now = new Date();
	month = now.getMonth()+1;
	day = now.getDate();
	weekday = w[now.getDay()]
	ele.innerHTML = '<p><span>'+month+'</span>月<span>'+day+'</span>日（'+weekday+'曜日）</p>';
}

function googleTranslateElementInit() {
	new google.translate.TranslateElement({
	pageLanguage: 'ja'
	//,includedLanguages: 'es,pt,en,ko,zh-CN,zh-TW',
	,autoDisplay: true
	,layout: google.translate.TranslateElement.InlineLayout.SIMPLE
//	,layout: google.translate.TranslateElement.InlineLayout.HORIZONTAL
	}, 'google_translate_element');
}
