function getDomain()
{
	myDomain = document.domain;
	if(myDomain == "www.occard.co.jp") myDomain = "www.occard.jp";
	return myDomain;
}
function Goto_Online(head,url)
{
	myUrl = head + '://' + getDomain()  + url;
	document.location.href=myUrl;
}

function Goto_Online2(head,url)
{
	myUrl = head + '://' + getDomain()  + url;
	info = window.open(myUrl,"info","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=800,height=800");
	info.focus() ;
}
function Goto_Online3(head,url)
{
	myUrl = head + '://' + getDomain()  + url;
	info = window.open(myUrl,"info","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes");
	info.focus() ;
}
function Goto_Submit(step)
{
	document.form.step_no.value = step;
	myUrl = 'https://' + getDomain()  + '/~online/net_service/';
	document.form.action = myUrl;
	document.form.submit();
}

function Goto_Submit2(step)
{
	document.form.step_no.value = step;
	myUrl = 'https://' + getDomain()  + '/~online/internet_service/cgi-bin/login.api';
	document.form.action = myUrl;
	document.form.submit();
}

function Goto_Imformation(url)
{
	info = window.open(url,"info","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=800,height=400");
	info.focus() ;
}
function showSubWindow(aUri, aWidth, aHeight)
{
	var vOptions = '';
	vOptions += 'toolbar=1, location=1, directories=0, status=1';
	vOptions += ', menubar=1, scrollbars=1, resizable=1';
	vOptions += ', width=' + aWidth + ', height=' + aHeight;
	subWindow = window.open(aUri, 'subWindow', vOptions);
	subWindow.focus();
}
function Goto_Menu(text)
{
	document.location.href = text;
}

// ページヘッダ & フッタ
rtPath = new String();
rtSslPath = new String();

function getRootPath()
{
	rtPath = document.location.href;

	switch(location.protocol)
	{
		case "file:":
			rtPath = rtPath.match(/^file:\/\/[^\/]*\/[^\/]+\/[^\/]+\/[^\/]+\/[^\/]+\//);
			rtSslPath = rtPath;
			break;
		case "http:":
			rtPath = rtPath.match(/^http:\/\/[^\/]+\//) + "";
			rtSslPath = rtPath.replace(/^http/,"https");
			break;
		case "https:":
			rtSslPath = rtPath.match(/^https:\/\/[^\/]+\//) + "";
			rtPath = rtSslPath.replace(/^https/,"http");
			break;
		default:
			rtPath = "";
			rtSslPath = "";
	}
}

function ocMenu(isXhtml) {
	getRootPath();
	document.writeln("<h1><a href=\"" + rtPath + "index.html\">株式会社オーシー |　OC CARD</a></h1>");
	document.writeln("<div id=\"mejirushi\"></div>");
	document.writeln("<div id=\"inquiry\"><a href=\"" + rtPath + "member/toiawase.html\" id=\"inq_label\">各種お問合せ</a></div>");
	document.writeln("<div id=\"qa_srch\">");
	document.writeln("<a href=\"" + rtPath + "qa/\" id=\"qa_link\">Q&amp;A</a>");
	document.writeln("<form action=\"" + rtPath + "qa/\" method=\"POST\">");
	document.writeln("<input type=\"text\" name=\"QASEARCH\" size=\"17\" maxlength=\"32\" title=\"単語の区切りは半角または全角のスペースです。\">");
	document.writeln("<input type=\"submit\" value=\"検索\" title=\"Ｑ＆ＡをＡＮＤ検索します。\"></form></div>");
	document.writeln("<hr />");
	document.writeln("<div id=\"menu_back\">");
	document.writeln("<div id=\"menu\">");
	document.writeln("<ul compact=\"compact\" class=\"main\">");
	document.writeln("<li class=\"off\" onmouseover=\"this.className='on'\" onmouseout=\"this.className='off'\"><a href=\"#\" class=\"menu_01\">カードのご紹介</a>");
	document.writeln("<ol class=\"sub\">");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "card/index.html\">カードラインナップ</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "card/oc/index.html\">OCカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_gold/index.html\">OCゴールドカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_premium/index.html\">OCプレミアムカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "card/tokiwa/index.html\">トキハカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "card/trinita/index.html\">大分トリニータカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "card/rakucchi/index.html\">RAKUCCHI</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_loan/natura.html\">ナチュラカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "etc/index.html\">ETCカード</a></li>");
	document.writeln("</ol>");
	document.writeln("</li>");
	document.writeln("<li class=\"off\" onmouseover=\"this.className='on'\" onmouseout=\"this.className='off'\"><a href=\"#\" class=\"menu_02\">ローンのご紹介</a>");
	document.writeln("<ol class=\"sub\">");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_loan/index.html\">ローン商品一覧</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_loan/natura.html\">ナチュラカード</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_loan/mycar_loan.html\"><span>自動車ローン</span></a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_loan/kyoiku_loan.html\">教育ローン</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "oc_loan/wideloan_loan.html\">ワイドローン</a></li>");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"javascript:Goto_Online2('https','/~online/hensai_simulation/cgi-bin/');\">返済シュミレーション</a></li>");
	document.writeln("</ol>");
	document.writeln("</li>");
	document.writeln("<li class=\"off\" onmouseover=\"this.className='on'\" onmouseout=\"this.className='off'\"><a href=\"#\" class=\"menu_03\">ATMのご案内</a>");
	document.writeln("<ol class=\"sub\">");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "service_spot/index.html\">ATMコーナー</a></li>");
	document.writeln("</ol>");
	document.writeln("</li>");
	document.writeln("<li class=\"off\" onmouseover=\"this.className='on'\" onmouseout=\"this.className='off'\"><a href=\"#\" class=\"menu_04\">その他の商品</a>");
	document.writeln("<ol class=\"sub\">");
	document.writeln("<li class=\"off2\" onmouseover=\"this.className='on2'\" onmouseout=\"this.className='off2'\"><a href=\"" + rtPath + "taxi_ticket/index.html\">タクシーチケット</a></li>");
	document.writeln("</ol>");
	document.writeln("</li>");
	document.writeln("</ul>");
	document.writeln("</div>");
	document.writeln("</div>");
}

function ocFooter(isXhtml)
{
	var sepa = "　|　";

	getRootPath();
	document.write("<div class=\"footer_menu\">");
	document.write("<a href=\"" + rtPath + "member/index.html\">会員規約</a>" + sepa);
	document.write("<a href=\"" + rtPath + "info/credit_policy.pdf\" target=\"_blank\" title=\"別ウィンドウで表示\">クレジットポリシー</a>" + sepa);
	document.write("<a href=\"" + rtPath + "corp/ethic_guideline.html\">倫理綱領</a>" + sepa);
	document.write("<a href=\"" + rtPath + "corp/kameiten_kyodoriyo.pdf\" target=\"_blank\" title=\"別ウィンドウで表示\">加盟店情報の共同利用について</a>" + sepa);
	document.write("<a href=\"javascript:Goto_Imformation('./whats_new/shinyou/index.html#deal');\" title=\"別ウィンドウで表示\">WEBにおける取り扱いについて</a><br />");
	document.write("<a href=\"" + rtPath + "corp/kan-yuu.html\">勧誘指針</a>" + sepa);
	document.write("<a href=\"" + rtPath + "corp/privacy.pdf\" target=\"_blank\" title=\"別ウィンドウで表示\">個人情報保護方針</a>" + sepa);
	document.write("<a href=\"" + rtPath + "corp/shinyou/puii.html\">個人情報保護法に基づく公表事項</a>" + sepa);
	document.write("<a href=\"" + rtPath + "corp/antisocial.pdf\" target=\"_blank\" title=\"別ウィンドウで表示\">反社会的勢力による被害防止のための基本方針</a>");
	document.write("</div>");
}

function ocLoanFooter() {
	getRootPath();
	document.write("<br />");
	document.write("<table style=\"width:100%;font-size:10px;color:#999999;\">");
	document.write("<tr><td style=\"border-top:1px #999999 dotted;\">&nbsp;</td></tr>");
	document.write("<tr><td style=\"border:1px #999999 solid;padding:1em;\">");
	document.write("商品についてのお問い合わせは");
	document.write("<div style=\"padding: 0.6em 0em;font-size:14px;font-weight:bold;color:black;\">");
	document.write("オーシーカスタマーセンター");
	document.write("</div>");
	document.write("<span style=\"font-size:14px;font-weight:bold;color:black;\">TEL 097-537-0404</span>");
	document.write("　営業時間　平日 9:00〜17:00（土・日・祝日は除く）");
	document.write("</td></tr>");
	document.write("<tr><td style=\"padding:1em;\">");
	document.write("<div style=\"padding: 0em 0em 1em;font-weight:bold;\">");
	document.write("貸付け条件の確認をし、借りすぎに注意しましょう。<br />ご利用は、計画的に。");
	document.write("</div>");
	document.write("<span style=\"font-size:14px;\">株式会社オーシー</span><br />");
	document.write("大分県大分市末広町2丁目3番28号　TEL:097-537-0404<br />");
	// returnValue.js を読み込んでおくこと
	document.write("登録番号&nbsp;" + getIdNum(4) + "<br />");
	document.write("&emsp;&emsp;&emsp;&emsp;&nbsp;" + getIdNum(1) + "/" + getIdNum(2));
	document.write("</td></tr>");
	document.write("<tr><td style=\"border:1px #999999 solid;padding:1em;\">");
	document.write("<div style=\"padding: 0.6em 0em;\">");
	document.write("<img src=\"" + rtPath + "oc_loan/images/jfsalogo.gif\" alt=\"日本貸金業協会\" />");
	document.write("</div>");
	document.write("貸金業相談・紛争解決センター　（借入や返済でお困りの時はご相談ください）<br />");
	document.write("TEL&nbsp;0570-051-051　受付時間\&nbsp;9:00〜17:30（土・日・祝日、年末年始は除く）");
	document.write("</td></tr>");
	document.write("</table>");
}

function ocLeftMenu() {
	getRootPath();
	document.writeln("<h3 class=\"menu_l_01_title\">OCカード会員様向け情報</h3>");
	document.writeln("<ul>");
	document.writeln("<li class=\"menu_l_01_11\"><a href=\"" + rtPath + "member/shouhinken_riyoukanou.pdf\" target=\"_blank\">商品券が利用できる加盟店一覧</a></li>");
	document.writeln("<li class=\"menu_l_01_1\"><a href=\"" + rtPath + "service_waribiki/index.html\">提示割引サービス店一覧</a></li>");
	document.writeln("<li class=\"menu_l_01_2\"><a href=\"" + rtPath + "member/hospital/index.html\">病院加盟店一覧</a></li>");
	document.writeln("<li class=\"menu_l_01_4\"><a href=\"javascript:Goto_Online('https','/~online/net_uketuske/index.api?modify=1');\">各種変更手続き</a></li>");
	document.writeln("<li class=\"menu_l_01_10\"><a href=\"" + rtPath + "member/increase/index.html\">増額お申込</a></li>");
	document.writeln("<li class=\"menu_l_01_5\"><a href=\"" + rtPath + "info/tounan.html\">紛失・盗難</a></li>");
	document.writeln("<li class=\"menu_l_01_6\"><a href=\"" + rtPath + "oc_card/tel.html\">国際電話のかけ方</a></li>");
	document.writeln("<li class=\"menu_l_01_7\"><a href=\"javascript:Goto_Online2('https','/~online/hensai_simulation/cgi-bin/');\">返済シュミレーション</a></li>");
	document.writeln("<li class=\"menu_l_01_8\"><a href=\"" + rtPath + "atm_usage/index.html\">ATMのご利用方法</a></li>");
	document.writeln("<li class=\"menu_l_01_9\"><a href=\"" + rtPath + "qa/\">Ｑ＆Ａ　よくある質問</a></li>");
	document.writeln("</ul>");
	document.writeln("</div>");
	document.writeln("</div>");
	document.writeln("<hr />");
	document.writeln("<div class=\"common_box\">");
	document.writeln("<div class=\"menu_left\">");
	document.writeln("<h3 class=\"menu_l_02_title\">店舗様向け情報</h3>");
	document.writeln("<ul>");
	document.writeln("<li class=\"menu_l_02_1\"><a href=\"" + rtPath + "kameiten/index.html\">OC加盟店契約のご案内</a></li>");
	document.writeln("</ul>");
	document.writeln("</div>");
	document.writeln("</div>");
	document.writeln("<hr />");
	document.writeln("<div class=\"common_box\"><a href=\"" + rtPath + "cm/index.html\"><img src=\"" + rtPath + "images/banner_cm.png\" alt=\"CMライブラリー\" width=\"160\" height=\"40\" border=\"0\" /></a></div>");
	document.writeln("<div class=\"common_box\"><a href=\"" + rtPath + "corp/recruit/index.html\"><img src=\"" + rtPath + "images/banner_saiyou.png\" alt=\"採用情報\" width=\"160\" height=\"40\" border=\"0\" /></a></div>");
	document.writeln("<div class=\"common_box\">");
	document.writeln("<div class=\"menu_l_03\">");
	document.writeln("<ul>");
	document.writeln("<li class=\"menu_l_03_1\"><a href=\"" + rtPath + "kaisya_gaiyo/index.html\">会社概要</a></li>");
	document.writeln("<li class=\"menu_l_03_2\"><a href=\"" + rtPath + "group/index.html\">OCグループ紹介</a></li>");
	document.writeln("<ul>");
	document.writeln("<li class=\"menu_l_03_3\"><a href=\"" + rtPath + "octravel/index.html\">オーシートラベル</a></li>");
	document.writeln("<li class=\"menu_l_03_5\"><a href=\"" + rtPath + "ocsystem/index.html\">OC システム</a></li>");
	document.writeln("<li class=\"menu_l_03_4\"><a href=\"http://www.ada-advance.jp/\">エーディーエーアドバンス</a></li>");
	document.writeln("</ul>");
	document.writeln("</ul>");
}

