/*----- Menu ----- */
//*** 메인메뉴 ***//
function menu0101(){ // CEO인사말
  document.location.href="../company/introduction.php";
}
function menu0102(){ // 경영이념&CI
  document.location.href="../company/philosophy.php";
}
function menu0103(){ // 회사연혁
  document.location.href="../company/history.php";
}
function menu0104(){ // 사업영역
  document.location.href="../company/business_area.php";
}
function menu0105(){ // 조직구성도
  document.location.href="../company/organization.php";
}
function menu0106(){ // 사업장정보
  document.location.href="../company/location.php";
}
function menu0107(){ // 계열사소개
  document.location.href="../company/subsidiary.php";
}
function menu0108(){ // 주요고객사
  document.location.href="../company/customer.php";
}
function menu0109(){ // 품질 및 환경방침
  document.location.href="../company/ideology.php";
}
function menu0110(){ // 윤리이념
  document.location.href="../company/morality.php";  
}
function menu0201(){ // SBIC 제품리스트
  document.location.href="../products/list_0101.php";
}
function menu020101(){ // GROUND ENGAGING TOOLS
  document.location.href="../products/list_0101.php";
}
function menu020102(){ // UNDERCARRIAGE PARTS
  document.location.href="../products/list_0102.php";
}
function menu020103(){ // OTHER STEEL CASTINGS
  document.location.href="../products/list_0103.php";
}
function menu020104(){ // OTHER STEEL CASTINGS
  document.location.href="../products/list_0103.php";
}
//function menu0202(){ // SBP&T 제품리스트
//  document.location.href="../products/list_02.php";
//}
function menu0203(){ // SBIC CHINA 제품 리스트
  document.location.href="../products/list_0301.php";
}
function menu0204(){ // 생산공정
  document.location.href="../products/list_04.php";
}
function menu0301(){ // 연구개발
  document.location.href="../research/rnd.php";
}
function menu0302(){ // 품질인증
  document.location.href="../research/certification.php";
}
function menu0401(){ // 온라인상담
  document.location.href="../service/inquiry_write.php";
}
function menu0402(){ // 공지사항
  document.location.href="../service/notice_list.php";
}
function menu0403(){ // FAQ
  document.location.href="../service/faq_list.php";
}
function menu0404(){ // Q&A
  document.location.href="../service/qna_list.php";
}
function menu0405(){ // 웹카다로그
  document.location.href="../service/catalog_list.php";
}
function menu0406(){ // 홍보영상
  document.location.href="../service/video.html";
}
function menu0501(){ // 채용정보
  document.location.href="../recruit/recruit_info.php";
}
function menu0502(){ // 채용FAQ
  document.location.href="../recruit/recruit_faq_list.php";
}
function menu0503(){ // 채용Q&A
  document.location.href="../recruit/recruit_qna_list.php";
}
function menu0504(){ // 온라인 입사지원
  document.location.href="../recruit/recruit_submit_write.php";
}
function menu0601(){ // 커뮤니티 로그인
  document.location.href="../community/login.php";
}
function menu0701(){ // 인트라넷 로그인
  document.location.href="javascript:MM_openBrWindow('http://www.sbic.co.kr/intranet/login/login.htm','intra','scrollbars=yes,resizable=yes,width=1024,height=768,top=0,left=0');";
}

//*** 상단 메뉴 ***//
function menu11(){ // HOME
  document.location.href="../main/main.php";
}
function menu12(){ // LOCATION
  document.location.href="../company/location.php";
}
function menu13(){ // SITEMAP
  document.location.href="../service/sitemap.php";
}
function menu14(){ // E-MAIL
  document.location.href="mailto:sbic@sbic.co.kr";
}

//*** 언어버전 선택 ***//
function menu21(){ // KOREAN
  document.location.href="../../korean/main/main.php";
}
function menu22(){ // ENGLISH
  document.location.href="../../english/main/main.php";
}
function menu23(){ // JAPANESE
  document.location.href="../../japanese/main/main.php";
}
function menu24(){ // CHINESE
  document.location.href="../../chinese/main/main.php";
}


/*----- onMouseOver Effect ----- */
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}


/*----- Layer Show/Hide ----- */
function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}


/*----- Open New Window ----- */
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}


/*-----  Sliding Layer script ----- */
browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);
if(browserName == "Netscape" && browserVer >= 3) {
  init = "net";
} else {
  init = "ie";
}

var _scroll_topmargin=270;      /* 이동 메뉴의 상단 한계 픽셀 */
var _scroll_ing_topmargin=150;    /* 움직이는 도중의 상단과의 간격 */
var _scroll_activate_speed=0;   /* 초기 움직임을 감지하는 시간차이 (1/1000초) */
var _scroll_ing_activate_speed=0;/* 움직이기 시작한 이후에 감지하는 시간차이 (1/1000초) */

var isDOM = (document.getElementById ? true : false);
var isIE4 = ((document.all && !isDOM) ? true : false);
var isNS4 = (document.layers ? true : false);

function getRef(id) {
  if (isDOM) return document.getElementById(id);
  if (isIE4) return document.all[id];
  if (isNS4) return document.layers[id];
}

var isNS = navigator.appName == "Netscape";

function moveRightEdge() {
  var yMenuFrom, yMenuTo, yOffset, timeoutNextCheck;
  if (isNS4) {
    yMenuFrom   = divMenu.top;
    yMenuTo     = windows.pageYOffset+_scroll_ing_topmargin;
  } else if (isDOM) {
    yMenuFrom   = parseInt (divMenu.style.top, 10);
    yMenuTo     = (isNS ? window.pageYOffset : document.body.scrollTop)+_scroll_ing_topmargin;
  }
  if(yMenuTo<_scroll_topmargin) yMenuTo = _scroll_topmargin;

  timeoutNextCheck = _scroll_activate_speed;

  if (yMenuFrom != yMenuTo) {
    yOffset = Math.ceil(Math.abs(yMenuTo - yMenuFrom) / 10);
    if (yMenuTo < yMenuFrom) yOffset = -yOffset;
    if (isNS4) divMenu.top += yOffset;
    else if (isDOM) divMenu.style.top = parseInt (divMenu.style.top, 10) + yOffset;
    timeoutNextCheck = _scroll_ing_activate_speed;
  }
  setTimeout ("moveRightEdge()", timeoutNextCheck);
}


/*----- Popup Message ----- */
function MM_popupMsg(msg) { //v1.0
  alert(msg);
}


/*----- 링크 점선 없애기 -----*/
function bluring() {
	if(event.srcElement.tagName=="A"||event.srcElement.tagName=="IMG") {
		document.body.focus();
	}
}
document.onfocusin=bluring;


/*----- Flash Script ----- */
function write_swf(src,w,h) {
  html = '';
  html += '<object type="application/x-shockwave-flash" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" id="param" width="'+w+'" height="'+h+'">';
  html += '<param name="movie" value="'+src+'">';
  html += '<param name="quality" value="high">';
  html += '<param name="bgcolor" value="#ffffff">';
  html += '<param name="swliveconnect" value="true">';
  html += '<param name="menu" value="false">';
  html += '<param name="wmode" value="transparent">';
  html += '<embed src="'+src+'" quality=high wmode="transparent" bgcolor="#ffffff" width="'+w+'" height="'+h+'" swliveconnect="true" id="param" name="param" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"><\/embed>';
  html += '<\/object>';
  document.write(html);
  }

  function write_embed(src,w,h,autostart,loop) {
  html = '';
  html += '<embed autostart="'+autostart+'" AllowScriptAccess="never" style="width:'+w+'px; height:'+h+'px;" type="application\/x-mplayer2" EnableContextMenu="false" loop="'+loop+'" autosize="0" src="'+src+'">';
  html += '<\/embed>';
  document.write(html);
}


/*----- FAQ Show/Hide ----- */
var old_menu = '';
function menuclick(num) {
  var answer = eval('faq_' + num);
  if(old_menu != answer) {
    if(old_menu != '') old_menu.style.display = 'none';
    answer.style.display = 'block';
    old_menu = answer;
  } else {
    answer.style.display = 'none';
    old_menu = '';
  }
}


/*----- Change Image ----- */
function Cng1(ImgName) { 
PathImg = "../images/products/"+ImgName;
    if(ImgName != "") {
    document.all.Big1.filters.blendTrans.stop();
    document.all.Big1.filters.blendTrans.Apply();
    document.all.Big1.src=PathImg;
    document.all.Big1.filters.blendTrans.Play();
  }
document['Big1'].src = PathImg;
}

function Cng2(ImgName) { 
PathImg = "../images/products/"+ImgName;
    if(ImgName != "") {
    document.all.Big2.filters.blendTrans.stop();
    document.all.Big2.filters.blendTrans.Apply();
    document.all.Big2.src=PathImg;
    document.all.Big2.filters.blendTrans.Play();
  }
document['Big2'].src = PathImg;
}

function Cng3(ImgName) { 
PathImg = "../images/products/"+ImgName;
    if(ImgName != "") {
    document.all.Big3.filters.blendTrans.stop();
    document.all.Big3.filters.blendTrans.Apply();
    document.all.Big3.src=PathImg;
    document.all.Big3.filters.blendTrans.Play();
  }
document['Big3'].src = PathImg;
}

function Cng4(ImgName) { 
PathImg = "../images/products/"+ImgName;
    if(ImgName != "") {
    document.all.Big4.filters.blendTrans.stop();
    document.all.Big4.filters.blendTrans.Apply();
    document.all.Big4.src=PathImg;
    document.all.Big4.filters.blendTrans.Play();
  }
document['Big4'].src = PathImg;
}

function Cng5(ImgName) { 
PathImg = "../images/products/"+ImgName;
    if(ImgName != "") {
    document.all.Big5.filters.blendTrans.stop();
    document.all.Big5.filters.blendTrans.Apply();
    document.all.Big5.src=PathImg;
    document.all.Big5.filters.blendTrans.Play();
  }
document['Big5'].src = PathImg;
}

function Cng6(ImgName) { 
PathImg = "../images/products/"+ImgName;
    if(ImgName != "") {
    document.all.Big6.filters.blendTrans.stop();
    document.all.Big6.filters.blendTrans.Apply();
    document.all.Big6.src=PathImg;
    document.all.Big6.filters.blendTrans.Play();
  }
document['Big6'].src = PathImg;
}


