본문 바로가기

먹고살거/JS(Jquery)

Navigator plugin

HTML
<!--
wrapper for navigator elements -->
<div class="navi"></div>

<!-- wrapper -->
<div class="navi">
	<a href="0" class="active"/>
	<a href="1" class=""/>
	<a href="2" class=""/>
</div> 

CSS
/*
position and dimensions of the navigator */
.navi { margin-left:328px; width:200px; height:20px; } /* items inside navigator */ .navi a { width:8px; height:8px; float:left; margin:3px; background:url(../img/scrollable/arrow/navigator.png) 0 0 no-repeat; display:block; font-size:1px; } /* mouseover state */ .navi a:hover { background-position:0 -8px; } /* active state (current page state) */ .navi a.active { background-position:0 -16px; }

JS
//
initialize scrollable together with the navigator plugin
$("#browsable").scrollable().navigator();


조