案例:jQuery UI案例     状态:可编辑再运行    进入竖版
 运行结果 
AخA
 
1
<!doctype html>
2
<html lang="en">
3
<head>
4
  <meta charset="utf-8">
5
  <title>jQuery UI 工具提示框(Tooltip) - 视频播放器</title>
6
  <link rel="stylesheet" href="/css/jqu1.10.4/jquery-ui.min.css">
7
  <script src="/js/jqu/jquery.min1.10.2.js"></script>
8
  <script src="/js/jqu/jquery-ui.min1.10.4.js"></script>
9
  <link rel="stylesheet" href="jqueryui/style.css">
10
  <style>
11
  .player {
12
    width: 500px;
13
    height: 300px;
14
    border: 2px groove gray;
15
    background: rgb(200, 200, 200);
16
    text-align: center;
17
    line-height: 300px;
18
  }
19
  .ui-tooltip {
20
    border: 1px solid white;
21
    background: rgba(20, 20, 20, 1);
22
    color: white;
23
  }
24
  .set {
25
    display: inline-block;
26
  }
27
  .notification {
28
    position: absolute;
29
    display: inline-block;
30
    font-size: 2em;
31
    padding: .5em;
32
    box-shadow: 2px 2px 5px -2px rgba(0,0,0,0.5);
33
  }
34
  </style>
35
  <script>
36
  $(function() {
37
    function notify( input ) {
38
      var msg = "已选择 " + $.trim( input.data( "tooltip-title" ) || input.text() );
39
      $( "<div>" )
40
        .appendTo( document.body )
41
        .text( msg )
42
        .addClass( "notification ui-state-default ui-corner-bottom" )
43
        .position({
44
          my: "center top",
45
          at: "center top",
46
          of: window
47
        })
48
        .show({