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

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

 更新時間:2013年08月06日 11:18:20   作者:  
這篇文章介紹了jquery鼠標滑過提示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="分數(shù):740分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分數(shù):840分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分數(shù):940分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分數(shù):1040分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>
 <p title="分數(shù):1140分" class="tooltiptt">1個太陽、2個月亮、2個星星,共多少積分呢?</p>

效果如下:

相關(guān)文章

最新評論

无棣县| 安吉县| 彭州市| 黄山市| 武川县| 毕节市| 新津县| 泗洪县| 酒泉市| 宜黄县| 广南县| 铁力市| 泌阳县| 临泽县| 灯塔市| 乌海市| 上犹县| 潼关县| 清流县| 玉龙| 洮南市| 从江县| 沛县| 台安县| 甘南县| 徐州市| 和田市| 阳西县| 麻城市| 修文县| 潢川县| 平舆县| 乌拉特前旗| 遵化市| 布尔津县| 昌图县| 收藏| 库伦旗| 资中县| 邮箱| 磐石市|