最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

jquery鼠標(biāo)滑過提示title具體實現(xiàn)代碼

 更新時間:2013年08月06日 11:18:20   作者:  
這篇文章介紹了jquery鼠標(biāo)滑過提示title具體實現(xiàn)代碼,有需要的朋友可以參考一下

復(fù)制代碼 代碼如下:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
 <script type="text/javascript">
 $(function(){
     var x=20;
     var y=0;
     $(".tooltiptt").mouseover(function(e){
     this.mytitle=this.title;
     this.title="";
     var tooltipdi="<div id="tooltipdi"><span><b></b><em></em>"+this.mytitle+"</span></div>";
     $("body").append(tooltipdi);

     $("#tooltipdi").css(
     {
     "top": (e.pagey+y) + "px",
     "left": (e.pagex+x) + "px"
     }
     ).show("fast");
     }).mouseout(function(){
      this.title=this.mytitle;
      $("#tooltipdi").remove();
     }).mousemove(function(e){
     $("#tooltipdi").css({
     "top": (e.pagey+y) + "px",
     "left": (e.pagex+x) + "px"
     });
     });
 })
 </script>
 <style type="text/css">
 *{ margin:0; padding:0;}
 body{ font:14px "微軟雅黑"; line-height:2; color:#333;}
 p{ margin:20px; background:#eee; border-radius:5px; padding:0 10px; cursor:default}

 #tooltipdi{ position:absolute; right:0; top:0; float:left; z-index:99;}
 #tooltipdi span{ font:14px "微軟雅黑"; color:#666; float:left; background:#fff; border:1px solid #c8c8c8; padding:6px 12px; border-radius:5px;}
 #tooltipdi span b{ display:block; position:absolute; left:-13px; top:10px; font-size:0; line-height:0; width:0; height:0; border-color:transparent; border-style:dashed; border-width:7px; border-right-color:#c8c8c8; border-right-style:solid;}
 #tooltipdi span em{ display:block; position:absolute; left:-12px; top:10px; font-size:0; line-height:0; width:0; height:0; border-color:transparent; border-style:dashed; border-width:7px; border-right-color:#fff; border-right-style:solid;}

 </style>

 <p title="分?jǐn)?shù):740分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分?jǐn)?shù):840分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分?jǐn)?shù):940分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分?jǐn)?shù):1040分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分?jǐn)?shù):1140分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>

效果如下:

相關(guān)文章

最新評論

河西区| 紫阳县| 锡林浩特市| 婺源县| 永宁县| 凌海市| 江阴市| 陵川县| 鹿泉市| 若羌县| 铁岭县| 怀安县| 石泉县| 平乐县| 鄢陵县| 兴安盟| 东丽区| 江华| 宁强县| 兰州市| 安达市| 垣曲县| 西畴县| 来凤县| 定南县| 饶河县| 临颍县| 延边| 太和县| 西藏| 宝鸡市| 诏安县| 龙胜| 马鞍山市| 新和县| 汝州市| 大理市| 临泉县| 邵阳市| 隆尧县| 新郑市|