자바스크립트&css3가 안먹혀요!! 도와주세요!! ㅜ.ㅜ > 그누4 질문답변

그누4 질문답변

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기
기존 게시물은 열람만 가능합니다.

자바스크립트&css3가 안먹혀요!! 도와주세요!! ㅜ.ㅜ 정보

자바스크립트&css3가 안먹혀요!! 도와주세요!! ㅜ.ㅜ

본문

안녕하세요, 다름아니라 그누보드쓰고 있는데요,

네비게이션을 자바스크립트&css3 로 작업했습니다. (물론 펌 --;)

근데!! 망할 익스플로러에서는 동작을 안한다는겁니다...
(여기서 문제.. 그누보드말고 일반페이지에서는 작동합니다.물론 몇몇 css는 안먹지만요.)

크롬에서는 제대로 작동하고요.. 소스 어디를 수정해야 할거 같은데...당췌 모르겠습니다..!!

도와주세요! 급합니다...ㅜ.ㅜ

아! 그리고 한가지더 궁금한게 있는데요.. 그누보드에서는 margin:0 auto; << 이게 안먹히나요??

--------------------------- css & javascript --------------------------------------

<script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script>
  <script type="text/javascript">
  $(function() {
    if ($.browser.msie && $.browser.version.substr(0,1)<7)
    {
    $('li').has('ul').mouseover(function(){
      $(this).children('ul').css('visibility','visible');
      }).mouseout(function(){
      $(this).children('ul').css('visibility','hidden');
      })
    }
  });
  </script>



#menu:before,
#menu:after {
 content: "";
 display: table;
}
#menu:after {
 clear: both;
}
#menu {
 zoom:1;
}
#menu li {
 float: left;
 position: relative;
}
#menu a {
 float: left;
 padding: 15px 31px;
 color: #FFFFFF;
 font-family:Arial;
 font-size:14px;
 font-weight:bold;
 text-decoration: none;
 text-shadow: 0 1px 0 #000;
}
#menu li:hover > a {
 color: #bbff00;
}
*html #menu li a:hover { /* IE6 only */
 color: #bbff00;
}
#menu ul {
 margin: 20px 0 0 0;
 _margin: 0; /*IE6 only*/
 opacity: 0;
 visibility: hidden;
 position: absolute;
 top: 45px;
 left: 0;
 z-index: 9999;
 background: #252525;
 background: -moz-linear-gradient(#444, #111);
 background-image: -webkit-gradient(linear, left top, left bottom, from(#444), to(#111));
 background: -webkit-linear-gradient(#444, #111);
 background: -o-linear-gradient(#444, #111);
 background: -ms-linear-gradient(#444, #111);
 background: linear-gradient(#444, #111);
 -moz-box-shadow: 0 -1px rgba(255,255,255,.3);
 -webkit-box-shadow: 0 -1px 0 rgba(255,255,255,.3);
 box-shadow: 0 -1px 0 rgba(255,255,255,.3);
 -moz-border-radius: 3px;
 -webkit-border-radius: 3px;
 border-radius: 3px;
 -webkit-transition: all .2s ease-in-out;
 -moz-transition: all .2s ease-in-out;
 -ms-transition: all .2s ease-in-out;
 -o-transition: all .2s ease-in-out;
 transition: all .2s ease-in-out; 
}
#menu li:hover > ul {
 opacity: 1;
 visibility: visible;
 margin: 0;
}
#menu ul ul {
 top: 0;
 left: 150px;
 margin: 0 0 0 20px;
 _margin: 0; /*IE6 only*/
 -moz-box-shadow: -1px 0 0 rgba(255,255,255,.3);
 -webkit-box-shadow: -1px 0 0 rgba(255,255,255,.3);
 box-shadow: -1px 0 0 rgba(255,255,255,.3); 
}
#menu ul li {
 float: none;
 display: block;
 border: 0;
 _line-height: 0; /*IE6 only*/
 border-bottom: 1px solid #000;
 -moz-box-shadow: 0 1px 0 #111, 0 2px 0 #666;
 -webkit-box-shadow: 0 1px 0 #111, 0 2px 0 #666;
 box-shadow: 0 1px 0 #111, 0 2px 0 #666;
}
#menu ul li:last-child { 
 -moz-box-shadow: none;
 -webkit-box-shadow: none;
 box-shadow: none;   
}
#menu ul a {   
 padding: 10px;
 width: 170px;
 _height: 10px; /*IE6 only*/
 display: block;
 white-space: nowrap;
 float: none;
 text-transform: none;
 font-size:12px;
}
#menu ul a:hover {
 background-color: #0186ba;
 background-image: -moz-linear-gradient(#04acec,  #0186ba);
 background-image: -webkit-gradient(linear, left top, left bottom, from(#04acec), to(#0186ba));
 background-image: -webkit-linear-gradient(#04acec, #0186ba);
 background-image: -o-linear-gradient(#04acec, #0186ba);
 background-image: -ms-linear-gradient(#04acec, #0186ba);
 background-image: linear-gradient(#04acec, #0186ba);
}
#menu ul li:first-child > a {
 -moz-border-radius: 3px 3px 0 0;
 -webkit-border-radius: 3px 3px 0 0;
 border-radius: 3px 3px 0 0;
}
#menu ul li:first-child > a:after {
 content: '';
 position: absolute;
 left: 40px;
 top: -6px;
 border-left: 6px solid transparent;
 border-right: 6px solid transparent;
 border-bottom: 6px solid #252525;
}
#menu ul ul li:first-child a:after {
 left: -6px;
 top: 50%;
 margin-top: -6px;
 border-left: 0;
 border-bottom: 6px solid transparent;
 border-top: 6px solid transparent;
 border-right: 6px solid #3b3b3b;
}
#menu ul li:first-child a:hover:after {
 border-bottom-color: #04acec;
}
#menu ul ul li:first-child a:hover:after {
 border-right-color: #0299d3;
 border-bottom-color: transparent; 
}
#menu ul li:last-child > a {
 -moz-border-radius: 0 0 3px 3px;
 -webkit-border-radius: 0 0 3px 3px;
 border-radius: 0 0 3px 3px;
}

댓글 전체

음 .. 우선 저도 그누보드에 대해선 잘 모르니 다른분이 답변해 주실거고요 -_ㅜ;
간단히 css에 대해 말씀드리자면.. 웹표준과 밀접한 관계가 있습니다.
css2 ~ css3 의 버전들중에 많은 부분들이 웹표준을 준수해야 적용되는 것들이 있다는 것이지요.
html을 시작할때 문서타입(DTD)등을 표기해야 한다든가 하는 것들이죠.
가령 익스플로우의 경우 문서타입이 없다면 하위호환성을 위해 quirks-mode로 렌더링되기 때문에
질문하신 중앙정렬이 안될수도 있습니다.

그누보드의 head.sub.php를 보시면
<!-- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> -->
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=<?=$g4['charset']?>">
<title><?=$g4['title']?></title>
<link rel="stylesheet" href="<?=$g4['path']?>/style.css" type="text/css">
</head>

상단의 문서타입이 주석처리 되어 있고 html 4.01 버전인게 보이실텐데요.
어짜피 주석처리되서 작동되지 않으나 ... html4.01 과 xhtml 1 버전들과도 지원유무가 틀려지죠.
물론 quirks-mode로 랜더링되도 지원되는 많은 것들이 있으나 지원되지 않는 부분에서는 편법이 필요해 집니다. 중앙정렬같은 경우에는 부모엘리먼트에 text-align:center 와 같은 식으로 땜빵이 가능하죠

또한 파폭이나 크롬은 사용유저 대부분이 최신버전을 유지하기때문에 최신의 css3도 발빠르게 적용가능합니다만... 익스플로우의 경우 몇년에 한번 업데이트 되고 있는 실정이니 최신기술지원에 미비할수 밖에 없습니다. ie9버전도 다른 브라우저들보다 html5 , css3 지원이 미비하죠.
도움되시길~_~;;
전체 66,554 |RSS
그누4 질문답변 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1402호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT