3

有没有办法改变文本悬停时标题标签内容显示的速度/速度?

例如

<h1 title="show up title">
4

1 回答 1

3

this all require the JavaScript or jquery

try this

html

<h1   id="book" title="hello onw"  >the title </h1>

jquery

    $("#book").append("<em></em>");
 $("#book").hover(function() {
      $(this).find("em").animate({opacity: "show", top: "-75"}, "slow");
      var hoverText = $(this).attr("title");
      $(this).find("em").text(hoverText);
    }, function() {
      $(this).find("em").animate({opacity: "hide", top: "-85"}, "fast");
    });

check the fiddle

also check this out

于 2012-09-23T06:21:41.197 回答