亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

jQuery實現(xiàn)帶延遲效果的滑動菜單代碼

 更新時間:2015年09月02日 16:27:14   作者:企鵝  
這篇文章主要介紹了jQuery實現(xiàn)帶延遲效果的滑動菜單,涉及jquery鼠標事件操作頁面屬性定時變換的技巧,具有一定參考借鑒價值,需要的朋友可以參考下

本文實例講述了jQuery實現(xiàn)帶延遲效果的滑動菜單代碼。分享給大家供大家參考。具體如下:

這是一款基于jQuery的滑動菜單,鼠標移到某菜單項上,菜單的背景可以滑動過來,平滑的滑動效果,炫動的導(dǎo)航效果,相比沒有動畫的菜單,這款菜單真的挺不錯哦。

先來看看運行效果截圖:

在線演示地址如下:

http://demo.jb51.net/js/2015/jquery-delay-style-menu-nav-codes/

具體代碼如下:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>jQuery實用炫動的導(dǎo)航效果</title>
<meta http-equiv="content-type" content="text/html;charset=gb2312">
<style type="text/css">
.nav{width:960px;text-align:center;background:#06F;margin:0 auto;position:relative;}
.nav a{width:104px;height:41px;line-height:41px;display:inline-block;margin-right:30px;position:relative;z-index:11111;color:#FFF;}
.nav_bj{background:#F00;width:104px;height:41px;position:absolute;top:0;z-index:111;left:210px;}
</style>
<script src="jquery-1.6.2.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(function(){
 var xxx,re;
 $(".nav a").mouseover(function(){
  xxx=$(this).position().left;
  $(".nav_bj").animate({left:xxx})
  clearTimeout(re);
  }).mouseout(function(){
   clearTimeout(re);
   re=setTimeout(function(){
    $(".nav_bj").animate({left:210})
   },500);
  })
 })
</script>
</head>
<body>
<div class="nav">
<a href="#">首頁</a>
<a href="#">腳本之家</a>
<a href="#">腳本下載</a>
<a href="#">網(wǎng)頁特效</a>
<div class="nav_bj"></div>
</div>
</body>
</html>

希望本文所述對大家的jquery程序設(shè)計有所幫助。

相關(guān)文章

最新評論