Demonya bisa kawan-kawan lihat disini
- Cara membuatnya :
- Login blogger
- Rancangan, Edit Html, Cari kode ]]></b:skin>
- Dan Simpan kode berikut diatasnya :
/* ---------------
Vertikal scroll menu with jQuery
---------------------------------- */
#scroolvrtkl{
height:400px;
overflow:hidden;
position:relative;
background-color:#999;
}
#vrtikal {
width:100%;
list-style:none;
padding:0;
margin:0;
top:0;
position:relative;
height:100%;
width:300px;
}
#vrtikal li {
padding:10px 0;
text-align:right;
display:block;
cursor:hand;
cursor:pointer;
}
#vrtikal li a {
background:url() repeat #1f1f1f;
color:#ddd;
font-family:helvetica, arial, verdana;
font-size:9px;
font-weight:900;
display:inline;
padding:20px 8px 5px 20px;
text-decoration:none;
}
#vrtikal li span {
font-family:georgia, arial;
font-size:9px;
color:#464646;
}
Vertikal scroll menu with jQuery
---------------------------------- */
#scroolvrtkl{
height:400px;
overflow:hidden;
position:relative;
background-color:#999;
}
#vrtikal {
width:100%;
list-style:none;
padding:0;
margin:0;
top:0;
position:relative;
height:100%;
width:300px;
}
#vrtikal li {
padding:10px 0;
text-align:right;
display:block;
cursor:hand;
cursor:pointer;
}
#vrtikal li a {
background:url() repeat #1f1f1f;
color:#ddd;
font-family:helvetica, arial, verdana;
font-size:9px;
font-weight:900;
display:inline;
padding:20px 8px 5px 20px;
text-decoration:none;
}
#vrtikal li span {
font-family:georgia, arial;
font-size:9px;
color:#464646;
}
selanjunya cari kode </head> dan letakkan java script beikut tepat diatasnya :
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js' type='text/javascript'/>
<script language='javascript' src='http://kangdadang.googlecode.com/files/jquery.easing.1.3.js' type='text/javascript'/>
<script src='http://kangdadang.googlecode.com/files/jquery.color.js' type='text/javascript'/>
<script type='text/javascript'>
$(document).ready(function() {
//Background color, mouseover and mouseout
var colorOver = '#31b8da';
var colorOut = '#1f1f1f';
//Padding, mouseover
var padLeft = '20px';
var padRight = '20px';
//Default Padding
var defpadLeft = $('#vrtikal li a').css('paddingLeft');
var defpadRight = $('#vrtikal li a').css('paddingRight');
//Animate the LI on mouse over, mouse out
$('#vrtikal li').click(function () {
//Make LI clickable
window.location = $(this).find('a').attr('href');
}).mouseover(function (){
//mouse over LI and look for A element for transition
$(this).find('a')
.animate( { paddingLeft: padLeft, paddingRight: padRight}, { queue:false, duration:100 } )
.animate( { backgroundColor: colorOver }, { queue:false, duration:200 });
}).mouseout(function () {
//mouse oout LI and look for A element and discard the mouse over transition
$(this).find('a')
.animate( { paddingLeft: defpadLeft, paddingRight: defpadRight}, { queue:false, duration:100 } )
.animate( { backgroundColor: colorOut }, { queue:false, duration:200 });
});
//Scroll the vrtikal on mouse move above the #sidebar layer
$('#scroolvrtkl').mousemove(function(e) {
//Sidebar Offset, Top value
var s_top = parseInt($('#scroolvrtkl').offset().top);
//Sidebar Offset, Bottom value
var s_bottom = parseInt($('#scroolvrtkl').height() + s_top);
//Roughly calculate the height of the vrtikal by multiply height of a single LI with the total of LIs
var mheight = parseInt($('#vrtikal li').height() * $('#vrtikal li').length);
//I used this coordinate and offset values for debuggin
$('#debugging_mouse_axis').html("X Axis : " + e.pageX + " | Y Axis " + e.pageY);
$('#debugging_status').html(Math.round(((s_top - e.pageY)/100) * mheight / 2));
//Calculate the top value
//This equation is not the perfect, but it 's very close
var top_value = Math.round(( (s_top - e.pageY) /100) * mheight / 2);
//Animate the #vrtikal by chaging the top value
$('#vrtikal').animate({top: top_value}, { queue:false, duration:500});
});
});
</script>
<script language='javascript' src='http://kangdadang.googlecode.com/files/jquery.easing.1.3.js' type='text/javascript'/>
<script src='http://kangdadang.googlecode.com/files/jquery.color.js' type='text/javascript'/>
<script type='text/javascript'>
$(document).ready(function() {
//Background color, mouseover and mouseout
var colorOver = '#31b8da';
var colorOut = '#1f1f1f';
//Padding, mouseover
var padLeft = '20px';
var padRight = '20px';
//Default Padding
var defpadLeft = $('#vrtikal li a').css('paddingLeft');
var defpadRight = $('#vrtikal li a').css('paddingRight');
//Animate the LI on mouse over, mouse out
$('#vrtikal li').click(function () {
//Make LI clickable
window.location = $(this).find('a').attr('href');
}).mouseover(function (){
//mouse over LI and look for A element for transition
$(this).find('a')
.animate( { paddingLeft: padLeft, paddingRight: padRight}, { queue:false, duration:100 } )
.animate( { backgroundColor: colorOver }, { queue:false, duration:200 });
}).mouseout(function () {
//mouse oout LI and look for A element and discard the mouse over transition
$(this).find('a')
.animate( { paddingLeft: defpadLeft, paddingRight: defpadRight}, { queue:false, duration:100 } )
.animate( { backgroundColor: colorOut }, { queue:false, duration:200 });
});
//Scroll the vrtikal on mouse move above the #sidebar layer
$('#scroolvrtkl').mousemove(function(e) {
//Sidebar Offset, Top value
var s_top = parseInt($('#scroolvrtkl').offset().top);
//Sidebar Offset, Bottom value
var s_bottom = parseInt($('#scroolvrtkl').height() + s_top);
//Roughly calculate the height of the vrtikal by multiply height of a single LI with the total of LIs
var mheight = parseInt($('#vrtikal li').height() * $('#vrtikal li').length);
//I used this coordinate and offset values for debuggin
$('#debugging_mouse_axis').html("X Axis : " + e.pageX + " | Y Axis " + e.pageY);
$('#debugging_status').html(Math.round(((s_top - e.pageY)/100) * mheight / 2));
//Calculate the top value
//This equation is not the perfect, but it 's very close
var top_value = Math.round(( (s_top - e.pageY) /100) * mheight / 2);
//Animate the #vrtikal by chaging the top value
$('#vrtikal').animate({top: top_value}, { queue:false, duration:500});
});
});
</script>
simpan template.....
cara pemanggilannya, silahkan ssuaikan dengan keinginan kawan-kawan baik itu pada Edit htmlposting atau pada menu Rancangan, Tambah Gadget, Html/Java script :
<div id="debugging_mouse_axis"></div>
<div id="debugging_status"></div>
<div id="scroolvrtkl">
<ul id="vrtikal">
<li><a href="#">vrtikal 1 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 2 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 3 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 4 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 5 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 6 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 7 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 8 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 9 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 10 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 11 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 12 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 13 <span> / 2007</span></a></li>
<li><a href="#">SUPER LONG vrtikal vrtikal vrtikal vrtikal SIZE 14 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 15 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 16 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 17 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 18 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 19 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 20 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 21 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 22 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 5 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 23 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 24 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 25 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 26 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 27 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 28 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 29 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 30 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 31 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 32 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 33 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 34 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 35 <span> / 2007</span></a></li>
</ul>
</div>
<div id="debugging_status"></div>
<div id="scroolvrtkl">
<ul id="vrtikal">
<li><a href="#">vrtikal 1 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 2 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 3 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 4 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 5 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 6 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 7 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 8 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 9 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 10 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 11 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 12 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 13 <span> / 2007</span></a></li>
<li><a href="#">SUPER LONG vrtikal vrtikal vrtikal vrtikal SIZE 14 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 15 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 16 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 17 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 18 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 19 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 20 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 21 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 22 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 5 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 23 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 24 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 25 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 26 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 27 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 28 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 29 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 30 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 31 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 32 <span> / 2007</span></a></li>
<li><a href="#">vrtikal 33 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE 34 <span> / 2007</span></a></li>
<li><a href="#">vrtikal SIZE LONG 35 <span> / 2007</span></a></li>
</ul>
</div>
simpan.. dan selesai..........
Keterangan : sebagai tambahan. jika script http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js ini sudah ada pada template kawan-kawan, kawan semua tak perlu lagi mnambahkan script tadi pada template yang dipakai
Posting Komentar