[제나플러스] 레이어로 이루어진 간단한 메뉴 소스 입니다. > 팁앤테크

본문 바로가기

사이트 내 전체검색

뒤로가기 팁앤테크

[제나플러스] 레이어로 이루어진 간단한 메뉴 소스 입니다.

본문

<script language="JavaScript">
<!--
function show_layer(lyr) { // 전체 레이어의 새로크기
document.all[lyr].style.height='180px';
}

function hidden_layer(lyr) { // 타이틀 부분의 레이어 세로크기
document.all[lyr].style.height='30px';
}

function start() { // 전체 레이어의 타이틀 부분 세로크기 - 레이어 이름 지정
document.all.Layer1.style.height='30px';
document.all.Layer2.style.height='30px';
document.all.Layer3.style.height='30px';
}
//-->
</script>

<body onLoad="start()">

<!--
레이어 추가시
레이어 부분을 복사 후 id명을 바꾸고 이 바꾼 id명을 위 자스의 전체 레이어 부분에 추가한 후
롤오버 부분에 id명을 적으면 됨.
//-->
<div id="Layer1" style="position:absolute; width:150px; height:180px; z-index:1; left: 10px; top: 10px; background-color: #FFFFCC; cursor: hand; overflow: hidden" onMouseOver="show_layer('Layer1')"; onMouseOut="hidden_layer('Layer1')">
<table border="0" width="150" height="180" cellspacing="0" cellpadding="0">
<tr>
<th height="30" align="center">Menu No.1</th>
</tr>
<tr>
<td height="145" align="center">
Menu No.1 -a<br>
Menu No.1 -b<br>
Menu No.1 -c<br>
Menu No.1 -d<br>
Menu No.1 -e<br>
</td>
</tr>
</table>
</div>

<div id="Layer2" style="position:absolute; width:150px; height:180px; z-index:1; left: 170px; top: 10px; background-color: #FFFFCC; cursor: hand; overflow: hidden" onMouseOver="show_layer('Layer2')"; onMouseOut="hidden_layer('Layer2')">
<table border="0" width="150" height="180" cellspacing="0" cellpadding="0">
<tr>
<th height="30" align="center">Menu No.2</th>
</tr>
<tr>
<td height="145" align="center">
Menu No.2 -a<br>
Menu No.2 -b<br>
Menu No.2 -c<br>
Menu No.2 -d<br>
Menu No.2 -e<br>
</td>
</tr>
</table>
</div>

<div id="Layer3" style="position:absolute; width:150px; height:180px; z-index:1; left: 330px; top: 10px; background-color: #FFFFCC; cursor: hand; overflow: hidden" onMouseOver="show_layer('Layer3')"; onMouseOut="hidden_layer('Layer3')">
<table border="0" width="150" height="180" cellspacing="0" cellpadding="0">
<tr>
<th height="30" align="center">Menu No.3</th>
</tr>
<tr>
<td height="145" align="center">
Menu No.3 -a<br>
Menu No.3 -b<br>
Menu No.3 -c<br>
Menu No.3 -d<br>
Menu No.3 -e<br>
</td>
</tr>
</table>
</div>
           
추천0

댓글목록 1

pahs님의 댓글

pahs쪽지보내기 메일보내기 자기소개 아이디로 검색 전체게시물 작성일

감사합니다.

전체 285건 10 페이지
게시물 검색
Copyright (c) 株式会社YHPLUS. All rights reserved.

사이트 정보

株式会社YHPLUS / 대표 : ZERO
〒171-0014 東京都豊島区池袋2-41-5 アーバン154 8F
050-5539-7787
오픈카카오톡 (YHPLUS) :
https://open.kakao.com/o/slfDj15d

PC 버전으로 보기