var para_height = 0;
var para_control = 0;
var para_layer=0;
var para_temp = 0;
function slide_Iframe(num,hs){
para_height = 145;
  if(num>0){
    document.all.hot.style.display="block";
    document.all.hot.style.borderLeft = "1px solid #AEAEA0"
    document.all.hot.style.borderRight = "1px solid #AEAEA0"
    if(num==1){
      document.images["slide_button1"].src = getImageRealName(document.images["slide_button1"].src)+"_on.gif";
			document.images["slide_button2"].src = getImageRealName(document.images["slide_button2"].src)+".gif";
			document.images["slide_button3"].src = getImageRealName(document.images["slide_button3"].src)+".gif";
			document.images["slide_button4"].src = getImageRealName(document.images["slide_button4"].src)+".gif";
			document.all.ifraLmenu.src=""
			document.all.ifraLmenu.src="http://news.chosun.com/common/L_mu_photo/index.html#"+hs;
			
      para_temp = 0;
      
    }else if (num==2){
      document.images["slide_button1"].src = getImageRealName(document.images["slide_button1"].src)+".gif";
			document.images["slide_button2"].src = getImageRealName(document.images["slide_button2"].src)+"_on.gif";
			document.images["slide_button3"].src = getImageRealName(document.images["slide_button3"].src)+".gif";
			document.images["slide_button4"].src = getImageRealName(document.images["slide_button4"].src)+".gif";
			document.all.ifraLmenu.src=""
			document.all.ifraLmenu.src="http://news.chosun.com/common/L_mu_photo/index.html#"+hs;
			
      para_temp = 0;

    }else if (num==3){
      document.images["slide_button1"].src = getImageRealName(document.images["slide_button1"].src)+".gif";
			document.images["slide_button2"].src = getImageRealName(document.images["slide_button2"].src)+".gif";
			document.images["slide_button3"].src = getImageRealName(document.images["slide_button3"].src)+"_on.gif";
			document.images["slide_button4"].src = getImageRealName(document.images["slide_button4"].src)+".gif";
			document.all.ifraLmenu.src=""
			document.all.ifraLmenu.src="http://news.chosun.com/common/L_mu_photo/index.html#"+hs;
			
      para_temp = 0;
    }else if (num==4){
      document.images["slide_button1"].src = getImageRealName(document.images["slide_button1"].src)+".gif";
			document.images["slide_button2"].src = getImageRealName(document.images["slide_button2"].src)+".gif";
			document.images["slide_button3"].src = getImageRealName(document.images["slide_button3"].src)+".gif";
			document.images["slide_button4"].src = getImageRealName(document.images["slide_button4"].src)+"_on.gif";
			document.all.ifraLmenu.src=""
			document.all.ifraLmenu.src="http://news.chosun.com/common/L_mu_photo/index.html#"+hs;
			
			para_temp = 0;
    }else{
      para_temp = 5;
    }
    setTimeout("layer_open()",500);
  }else{
		
    document.all.ifraLmenu.style.display="none";
		
    setTimeout("layer_close()",500);
  }
}
function layer_open(){
  if(para_control==0){
  temp = parseInt(document.all.hot.style.height.replace("px",""));
  temp = temp+10;
    if(temp <= para_height){
		stmnGAP1 = stmnGAP1 + 10;
		//stmnBASE = stmnBASE + 10;
    document.all.hot.style.height = temp;
    setTimeout("layer_open()",10);
    }else{
		stmnGAP1 = document.all.leftArea.clientHeight+ 188;
    document.all.hot.style.height = para_height;
		document.all.ifraLmenu.style.display="block";
    }
  }
}
function layer_close(){
  if(para_control==1){
  temp = parseInt(document.all.hot.style.height.replace("px",""));
  temp = temp-10;
    if(temp >= 0){
		stmnGAP1 = stmnGAP1 - 10;
		//stmnBASE = stmnBASE - 10;
    document.all.hot.style.height = temp;
    setTimeout("layer_close()",10);
    }else{
			stmnGAP1 = document.all.leftArea.clientHeight+188;
      document.all.hot.style.border = "0px";
      document.all.hot.style.display = "none";
      document.images["slide_button1"].src = getImageRealName(document.images["slide_button1"].src)+"_off.gif";
			document.images["slide_button2"].src = getImageRealName(document.images["slide_button2"].src)+"_off.gif";
			document.images["slide_button3"].src = getImageRealName(document.images["slide_button3"].src)+"_off.gif";
			document.images["slide_button4"].src = getImageRealName(document.images["slide_button4"].src)+"_off.gif";
    }
  }
}
function getImageRealName(str){
	str = str.replace(".gif","");
	str = str.replace("_off","");
	str = str.replace("_on","");
	return str;
}

var title ="";
var TempDate="";


var nowFontSz = 10 ; // À§ CSSÀÇ article°ú °°Àº Font Å©±â
var nowlineHei= 1.6 ; // À§ CSSÀÇ article°ú °°Àº Font Çà°£
var fontObj = new Array() ;
var tempObj = new Array();
var expTime = new Date() ;
    expTime.setTime(expTime.getTime()+(24*60*60*1000*365)) ; // 365ÀÏ°£ Àû¿ë
var cName1 = "mzFontSz" ;
var cName2 = "mzFontHei" ;
var cNameStr, cNameVal ;



function getCookie(){
 cNameStr = arguments[0] + "=" ;
 if (document.cookie){
   cStr_start = document.cookie.indexOf(cNameStr) ;
   if (cStr_start != -1){
    cStr_start += cNameStr.length ;
    cStr_end = document.cookie.indexOf(";", cStr_start) ;
    if (cStr_end == -1) cStr_end = document.cookie.length ;
    cNameVal = document.cookie.substring(cStr_start, cStr_end) ;
   }
 }
 if (cNameVal) return cNameVal ;
 else return null ;
}



function fontSz(){
	fontObj = getFontObj();
 // Font Resize
 if (arguments[0] == "-"){
  if (nowFontSz <= 9) return ;
	 for(i=0;i<fontObj.length;i++){
	  fontObj[i].fontSize = nowFontSz-1 + "pt" ;
	 }
  nowFontSz = eval(nowFontSz-1) ;

  if(nowFontSz < 13){
	   for(i=0;i<fontObj.length;i++){
		 fontObj[i].lineHeight = nowlineHei+0.2 ;
	  }
	  nowlineHei = nowlineHei+0.2 ;
  }

 }else if (arguments[0] == "+"){
  if (nowFontSz >= 21) return ;
	 for(i=0;i<fontObj.length;i++){
	  fontObj[i].fontSize = nowFontSz+1 + "pt" ;
	  }
  nowFontSz = eval(nowFontSz+1) ;

  if(nowFontSz < 13){
	  for(i=0;i<fontObj.length;i++){
		fontObj[i].lineHeight = nowlineHei-0.2 ;
	  }
	  nowlineHei = nowlineHei-0.2 ;
 }  

 }
 // ResizeµÈ FontÀÇ °ªÀ» ÄíÅ°¿¡ Àû¿ë
 document.cookie = cName1 + "=" + nowFontSz + "; path=/" + "; expires=" + expTime.toGMTString() ;
 document.cookie = cName2 + "=" + nowlineHei + "; path=/" + "; expires=" + expTime.toGMTString() ;
}



function fontSet(){
 fontObj = getFontObj();
 // ÄíÅ°¿¡ Font°ª ÀÖÀ»½Ã Font¿¡ Àû¿ë
 if (getCookie(cName1)!=null || getCookie(cName2)!=null){
  getCookie(cName1) ;
  nowFontSz = eval(cNameVal) ;
  fontObj.fontSize = nowFontSz + "pt" ;
  getCookie(cName2) ;
  nowlineHei= eval(cNameVal) ;
  fontObj.lineHeight = nowlineHei ;
 }
}



/* 
¹è¿­ ¿©ºÎ °Ë»ç by ÀÌÀ±¼®
*/
function isarray( obj ) {
    try {
        var len = obj.length;
        if(len > 0) {
            return true;
        }
        else {
            return false;
        }
    }
    catch (e) {
        return false;
    }
}
/* 
¹è¿­ °¡Á®¿À±â by ÀÌÀ±¼®
*/
function getFontObj(){
	
  if (document.getElementsByName){
	if(isarray(document.getElementsByName("fontSzArea"))){
		for(i=0;i<document.getElementsByName("fontSzArea").length;i++){
		tempObj[i] = document.getElementsByName("fontSzArea")[i].style ;
		}
	}else{
		tempObj[0] = document.getElementsByName("fontSzArea").style;
	}
  } else if (document.all){
	 if(isarray(document.all("fontSzArea"))){
		for(i=0;i<document.all("fontSzArea").length;i++){
		tempObj[i] = document.all("fontSzArea")[i].style ;
		}
	 }else{
		tempObj[0] = document.all("fontSzArea").style;
	 }
	
  }
	return tempObj;
}





