// ============================ Start :: Font 관련 함수 =============================
  var article_fontSize = parseInt(getCookie("article_fontSize"));

  function initFont() {
    if ( (article_fontSize < 13) || (article_fontSize > 17) || (isNaN(article_fontSize) == true)) {
      article_fontSize = 12;  // 특별한, 폰트크기의 지정이 없을 경우 디폴트로 저장(쿠키로)되는 폰트 사이즈 입니다.
    }                        // 쿠키로 저장되는 경우, 어떤 스타일클래스보다 우선하게 됩니다.
    setFont(article_fontSize);
  }

  function setFont(article_fontSize) {
    document.getElementById("content").style.fontSize = article_fontSize+"px";
    //document.getElementById("content_view").style.fontSize = article_fontSize+"px";
    //document.getElementById("wrap").style.zoom = "200%";
    // 실제 HTML 페이지에서, 폰트조정에 사용할 엘리먼트 값:setFontBody (필요에 따라 엘리먼트 이름 변경 가능)
    setFontCookie(article_fontSize);
  }

  function setFontCookie(article_fontSize) {
    var expiry = new Date();
    var path = "/";
    var domain = ".seoul.go.kr";  // 다음 스크립트를 사용할 도메인에 맞게 사용해야 합니다.
    var secure = "";

    //expiry.setTime(expiry.getTime() + 90 * (24 * 60 * 60 * 1000));
    fontSetCookie("article_fontSize",article_fontSize,0);
  }

  function fontPlus() {	  
    if (article_fontSize < 16) {  // 최대 16pt 까지 크기설정을 할 수 있습니다.
      article_fontSize = article_fontSize + 1;
      setFont(article_fontSize);
    }
  }

  function fontMinus() {
    if (article_fontSize > 12) {  // 최소 12pt 까지 크기설정을 할 수 있습니다.
      article_fontSize = article_fontSize - 1;
      setFont(article_fontSize);
    }
  }
// ============================ End :: Font 관련 함수 =============================
window.onload = initFont;

