案例:HighCharts案例     状态:可编辑再运行    进入竖版
 运行结果 
x
 
1
<html>
2
<head>
3
<meta charset="UTF-8" />
4
<title>Highcharts 教程 | W3xue教程(w3xue.com)</title>
5
<script src="/js/jquery-2.1.4.min.js"></script>
6
<script src="/js/hc/highcharts5.0.6.js"></script>
7
<script src="https://cdn.bootcss.com/highcharts/5.0.10/highcharts-more.js"></script>  
8
</head>
9
<body>
10
<div id="container" style="width: 550px; height: 400px; margin: 0 auto"></div>
11
<script language="JavaScript">
12
$(document).ready(function() {  
13
  
14
   /**
15
   * 获取当前时间
16
   */
17
   function getNow() {
18
      var now = new Date();
19
      return {
20
         hours: now.getHours() + now.getMinutes() / 60,
21
         minutes: now.getMinutes() * 12 / 60 + now.getSeconds() * 12 / 3600,
22
         seconds: now.getSeconds() * 12 / 60
23
      };
24
   }
25
26
   /**
27
   * Pad numbers
28
   */
29
   function pad(number, length) {
30
      // Create an array of the remaining length + 1 and join it with 0's
31
      return new Array((length || 2) + 1 - String(number).length).join(0) + number;
32
   }
33
34
   var now = getNow();
35
36
37
   var chart = {      
38
      type: 'gauge',
39
      plotBackgroundColor: null,
40
      plotBackgroundImage: null,
41
      plotBorderWidth: 0,
42
      plotShadow: false,
43
      height: 200
44
   };
45
   var credits = {
46
      enabled: false
47
   };
48