<!--
//**********************************************************************
// SWCC：Header Navigation
// 2006.03.08
//**********************************************************************
// 変数：gHdxxx
// 関数：hd_xxx
//**********************************************************************

// [gSw_rootPath] : Document Root
// [gSw_imgPath]  : Image Directory

//---------------------------------------------
// Directory name + Image name
//---------------------------------------------
var gHdImgAct  = '';
var gHdImgName = {
	'index'    : 'hd_mn_home',  // 'index' is not directory name.
	'news'     : 'hd_mn_news_topi',
	'company'  : 'hd_mn_corp',
	'products' : 'hd_mn_pro',
	'inquiry'  : 'hd_mn_cont'
}

var gHdDefaultPath = gSw_rootPath + 'dt/';

var gHdUrl      = location.href;
var gHdFilePath = gHdUrl.substring(gHdUrl.indexOf(gHdDefaultPath) + gHdDefaultPath.length , gHdUrl.length);
var gHdDirName  = gHdFilePath.substring(0 , gHdFilePath.indexOf('/'));
if(( gHdUrl == gHdDefaultPath ) || ( gHdUrl.indexOf(gHdDefaultPath + 'index.htm') >= 0 )){ gHdDirName = 'index'; }

// Image name -> gHdImgName[gHdDirName]


//---------------------------------------------
// Data
//---------------------------------------------

gHdData = new Array();
gHdData[0] = '';
gHdData[1] = '<a href="'+ gSw_rootPath +'dt/index.htm" onMouseOver="hd_over(\'hd_mn_home\');" onMouseOut="hd_out(\'hd_mn_home\');"><img name="hd_mn_home" src="'+ gSw_imgPath +'hd_mn_home.gif" width="90" height="43" alt="ホーム"></a>';
gHdData[2] = '<a href="'+ gSw_rootPath +'dt/news/index.htm" onMouseOver="hd_over(\'hd_mn_news_topi\');" onMouseOut="hd_out(\'hd_mn_news_topi\');"><img name="hd_mn_news_topi" src="'+ gSw_imgPath +'hd_mn_news_topi.gif" width="130" height="43" alt="ニュース＆トピックス"></a>';
gHdData[3] = '<a href="'+ gSw_rootPath +'dt/company/index.htm" onMouseOver="hd_over(\'hd_mn_corp\');" onMouseOut="hd_out(\'hd_mn_corp\');"><img name="hd_mn_corp" src="'+ gSw_imgPath +'hd_mn_corp.gif" width="110" height="43" alt="企業情報"></a>';
gHdData[4] = '<a href="'+ gSw_rootPath +'dt/products/index.htm" onMouseOver="hd_over(\'hd_mn_pro\');" onMouseOut="hd_out(\'hd_mn_pro\');"><img name="hd_mn_pro" src="'+ gSw_imgPath +'hd_mn_pro.gif" width="110" height="43" alt="製品情報"></a>';
gHdData[5] = '<a href="'+ gSw_rootPath +'dt/inquiry/index.htm" onMouseOver="hd_over(\'hd_mn_cont\');" onMouseOut="hd_out(\'hd_mn_cont\');"><img name="hd_mn_cont" src="'+ gSw_imgPath +'hd_mn_cont.gif" width="110" height="43" alt="お問合せ"></a>';


//---------------------------------------------
// Document Write
//---------------------------------------------

with( document ){
	write('<!-- ===== Head ===== -->');
	write('<table border="0" width="760" cellpadding="0" cellspacing="0">');
	write('<tr>');
	write('<td width="10"><img src="'+ gSw_imgPath +'sp.gif" width="1" height="1" alt=""></td>');
	write('<td width="740">');
	write('<div><img src="'+ gSw_imgPath +'sp.gif" width="1" height="10" alt=""></div>');
	write('<table border="0" width="740" cellpadding="0" cellspacing="0">');
	write('<tr>');
	write('<td rowspan="2">');
	write('<!-- logo -->');
	write('<table border="0" cellpadding="0" cellspacing="0">');
	write('<tr>');
	write('<td><a href="'+ gSw_rootPath +'dt/index.htm"><img src="'+ gSw_imgPath +'logo_swcc.gif" width="142" height="56" alt="SWCC GROUP Creating for the Future"></a></td>');
	write('<td><img src="'+ gSw_imgPath +'sp.gif" width="5" height="1" alt=""></td>');
	write('<td><img src="'+ gSw_imgPath +'logo_device.gif" width="276" height="31" alt="昭和電線デバイステクノロジー株式会社"></td>');
	write('</tr>');
	write('</table>');
	write('<!-- /logo -->');
	write('</td>');
	write('<td align="right" valign="top">');
	write('<!-- head_menu -->');
	write('<table border="0" cellpadding="0" cellspacing="0">');
	write('<tr>');
	write('<td><a href="'+ gSw_rootPath +'index.htm" target="hd" onMouseOver="hd_over(\'hd_mn4\');" onMouseOut="hd_out(\'hd_mn4\');"><img name="hd_mn4" src="'+ gSw_imgPath +'hd_mn4.gif" width="127" height="9" alt="昭和電線ホールディングスTOP"></a></td>');
	write('<td><img src="'+ gSw_imgPath +'sp.gif" width="10" height="1" alt=""></td>');
	write('<td><a href="'+ gSw_rootPath +'dt/sitemap.htm" onMouseOver="hd_over(\'hd_mn2\');" onMouseOut="hd_out(\'hd_mn2\');"><img name="hd_mn2" src="'+ gSw_imgPath +'hd_mn2.gif" width="60" height="9" alt="サイトマップ"></a></td>');
	write('<td><img src="'+ gSw_imgPath +'sp.gif" width="10" height="1" alt=""></td>');
	write('<td><a href="'+ gSw_rootPath +'eng/index.htm" target="hd" onMouseOver="hd_over(\'hd_mn3\');" onMouseOut="hd_out(\'hd_mn3\');"><img name="hd_mn3" src="'+ gSw_imgPath +'hd_mn3.gif" width="46" height="9" alt="English"></a></td>');
	write('</tr>');
	write('</table>');
	write('<!-- /head_menu -->');
	write('</td>');
	write('</tr>');
	write('<tr>');
	write('<td align="right" valign="bottom">');
	write('<!-- search -->');
	//write('<img src="'+ gSw_imgPath +'sp.gif" width="1" height="1" alt="">');
	//write('<table border="0" cellpadding="0" cellspacing="0">');
	//write('<form action="#####" method="XXXXX">');
	//write('<tr>');
	//write('<td><img src="'+ gSw_imgPath +'hd_search_txt.gif" width="59" height="10" alt="サイト内検索"></td>');
	//write('<td><img src="'+ gSw_imgPath +'sp.gif" width="10" height="1" alt=""></td>');
	//write('<td><input type="text" class="j12" name="xxxx" value=""></td>');
	//write('<td><img src="'+ gSw_imgPath +'sp.gif" width="10" height="1" alt=""></td>');
	//write('<td><input type="image" src="'+ gSw_imgPath +'hd_search_submit.gif" width="45" height="20" alt="検索"></td>');
	//write('</tr>');
	//write('</form>');
	//write('</table>');

	write('<table border="0" cellpadding="2" cellspacing="0">');
	write('<tbody>');
	write('<tr>');
	write('<td align="right">');
	write('<form style="margin-top:5px;" action="'+ gSw_rootPath +'search/" id="cse-search-box">');
	write('<div>');
	write('<input type="hidden" name="cx" value="001715775032713088627:1yqzav3e4ow" />');
	write('<input type="hidden" name="cof" value="FORID:10" />');
	write('<input type="hidden" name="ie" value="Shift_JIS" />');
	write('<input type="text" name="q" size="21" />');
	write('<input style="margin-left:10px;" type="submit" name="sa" value="検索" />');
	write('</div>');
	write('</form>');
	write('<script type="text/javascript" src="http://www.google.com/cse/brand?form=cse-search-box&lang=ja&sitesearch=true"></script>');
	write('</td>');
	write('</tr>');
	write('<tr>');
	write('<td>');
	write('<span id="fontsize">');
	write('<img src="'+ gSw_rootPath +'common/img/font_change.gif" alt="文字サイズの変更" style="float: left;">');
	write('<ul id="select">');
	write('<li><a href="javascript:setActiveStyleSheet(\'Small\'); return false;" onclick="setActiveStyleSheet(\'Small\'); return false;" id="fontsmall">小</a></li><li><a href="javascript:setActiveStyleSheet(\'medium\'); return false;" onclick="setActiveStyleSheet(\'medium\'); return false;" id="fontmiddle">中</a></li><li><a href="javascript:setActiveStyleSheet(\'Large\'); return false;" onclick="setActiveStyleSheet(\'Large\'); return false;" id="fontlarge">大</a></li>');
	write('</ul>');
	write('</span>');
	write('</td>');
	write('</tr>');
	write('</tbody>');
	write('</table>');

	write('<!-- /search -->');
	write('</td>');
	write('</tr>');
	write('</table>');
	write('<div><img src="'+ gSw_imgPath +'sp.gif" width="1" height="9" alt=""></div>');
	write('</td>');
	write('<td width="10"><img src="'+ gSw_imgPath +'sp.gif" width="1" height="1" alt=""></td>');
	write('</tr>');
	write('</table>');
	write('<!-- ===== /Head ===== -->');
	write('<!-- ===== Global_Menu ===== -->');
	write('<table border="0" width="760" cellpadding="0" cellspacing="0">');
	write('<tr>');
	write('<td background="'+ gSw_imgPath +'hd_mn_bg.gif">');
	write('<table border="0" cellpadding="0" cellspacing="0">');
	write('<tr>');

	for( var i = 1; i<gHdData.length; i++ ){
	//alert(i);
	write('<td>' + gHdData[i] + '</td>');
	}

	write('</tr>');
	write('</table>');
	write('</td>');
	write('</tr>');
	write('</table>');
	write('<!-- ===== /Global_Menu ===== -->');
	write('<div><img src="'+ gSw_imgPath +'sp.gif" width="1" height="20" alt=""></div>');
}

//---------------------------------------------
// Image Active
//---------------------------------------------
hd_active(gHdImgName[gHdDirName]);


//---------------------------------------------
// Image Loading
//---------------------------------------------

gHdImgArys = new Array(
	'hd_mn4.gif','hd_mn4_on.gif',
	'hd_mn2.gif','hd_mn2_on.gif',
	'hd_mn3.gif','hd_mn3_on.gif',

	'hd_mn_home.gif','hd_mn_home_on.gif',
	'hd_mn_news_topi.gif','hd_mn_news_topi_on.gif',
	'hd_mn_corp.gif','hd_mn_corp_on.gif',
	'hd_mn_pro.gif','hd_mn_pro_on.gif',
	'hd_mn_cont.gif','hd_mn_cont_on.gif'
);

gHdImgLoad = new Array();
for( var i = 0; i < gHdImgArys.length; i++ ){
	gHdImgLoad[i] = new Image();
	gHdImgLoad[i].src = gSw_imgPath + gHdImgArys[i];
	//document.write("<img src='" + gHdImgLoad[i].src + "'><br>");
}


//=============================================
// hd_over()
//=============================================
function hd_over(wk){
	var mDoc;
	var mExt;
	var mEnd = "_on";    //onMouseOver時のイメージファイル名の末尾
	
	if( document.images[wk] && gHdImgAct != wk){
		mDoc = document.images[wk];
		mExt = mDoc.src.substring(mDoc.src.lastIndexOf(".") , mDoc.src.length);
		
		mDoc.src = gSw_imgPath + wk + mEnd + mExt;
	}
}

//=============================================
// hd_out()
//=============================================
function hd_out(wk){
	var mDoc;
	var mExt;
	
	if( document.images[wk] && gHdImgAct != wk){
		mDoc = document.images[wk];
		mExt = mDoc.src.substring(mDoc.src.lastIndexOf(".") , mDoc.src.length);
		
		mDoc.src = gSw_imgPath + wk + mExt;
	}
}

//=============================================
// hd_active()
//=============================================
function hd_active(mName){
	var mDir = gSw_imgPath;
	if( document.images[mName] ){
		document.images[mName].src = mDir + mName + '_on.gif';
	}
	gHdImgAct = mName;
}


//**********************************************************************
-->

