市长热线演示版

index.htm 5.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. <!DOCTYPE HTML>
  2. <html>
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  5. <title>Highcharts Example</title>
  6. <script type="text/javascript" src="http://cdn.hcharts.cn/jquery/jquery-1.8.3.min.js"></script>
  7. <script type="text/javascript">
  8. $(function () {
  9. $('#container').highcharts({
  10. chart: {
  11. type: 'spline'
  12. },
  13. title: {
  14. text: 'Wind speed during two days'
  15. },
  16. subtitle: {
  17. text: 'October 6th and 7th 2009 at two locations in Vik i Sogn, Norway'
  18. },
  19. xAxis: {
  20. type: 'datetime',
  21. labels: {
  22. overflow: 'justify'
  23. }
  24. },
  25. yAxis: {
  26. title: {
  27. text: 'Wind speed (m/s)'
  28. },
  29. min: 0,
  30. minorGridLineWidth: 0,
  31. gridLineWidth: 0,
  32. alternateGridColor: null,
  33. plotBands: [{ // Light air
  34. from: 0.3,
  35. to: 1.5,
  36. color: 'rgba(68, 170, 213, 0.1)',
  37. label: {
  38. text: 'Light air',
  39. style: {
  40. color: '#606060'
  41. }
  42. }
  43. }, { // Light breeze
  44. from: 1.5,
  45. to: 3.3,
  46. color: 'rgba(0, 0, 0, 0)',
  47. label: {
  48. text: 'Light breeze',
  49. style: {
  50. color: '#606060'
  51. }
  52. }
  53. }, { // Gentle breeze
  54. from: 3.3,
  55. to: 5.5,
  56. color: 'rgba(68, 170, 213, 0.1)',
  57. label: {
  58. text: 'Gentle breeze',
  59. style: {
  60. color: '#606060'
  61. }
  62. }
  63. }, { // Moderate breeze
  64. from: 5.5,
  65. to: 8,
  66. color: 'rgba(0, 0, 0, 0)',
  67. label: {
  68. text: 'Moderate breeze',
  69. style: {
  70. color: '#606060'
  71. }
  72. }
  73. }, { // Fresh breeze
  74. from: 8,
  75. to: 11,
  76. color: 'rgba(68, 170, 213, 0.1)',
  77. label: {
  78. text: 'Fresh breeze',
  79. style: {
  80. color: '#606060'
  81. }
  82. }
  83. }, { // Strong breeze
  84. from: 11,
  85. to: 14,
  86. color: 'rgba(0, 0, 0, 0)',
  87. label: {
  88. text: 'Strong breeze',
  89. style: {
  90. color: '#606060'
  91. }
  92. }
  93. }, { // High wind
  94. from: 14,
  95. to: 15,
  96. color: 'rgba(68, 170, 213, 0.1)',
  97. label: {
  98. text: 'High wind',
  99. style: {
  100. color: '#606060'
  101. }
  102. }
  103. }]
  104. },
  105. tooltip: {
  106. valueSuffix: ' m/s'
  107. },
  108. plotOptions: {
  109. spline: {
  110. lineWidth: 4,
  111. states: {
  112. hover: {
  113. lineWidth: 5
  114. }
  115. },
  116. marker: {
  117. enabled: false
  118. },
  119. pointInterval: 3600000, // one hour
  120. pointStart: Date.UTC(2009, 9, 6, 0, 0, 0)
  121. }
  122. },
  123. series: [{
  124. name: 'Hestavollane',
  125. data: [4.3, 5.1, 4.3, 5.2, 5.4, 4.7, 3.5, 4.1, 5.6, 7.4, 6.9, 7.1,
  126. 7.9, 7.9, 7.5, 6.7, 7.7, 7.7, 7.4, 7.0, 7.1, 5.8, 5.9, 7.4,
  127. 8.2, 8.5, 9.4, 8.1, 10.9, 10.4, 10.9, 12.4, 12.1, 9.5, 7.5,
  128. 7.1, 7.5, 8.1, 6.8, 3.4, 2.1, 1.9, 2.8, 2.9, 1.3, 4.4, 4.2,
  129. 3.0, 3.0]
  130. }, {
  131. name: 'Voll',
  132. data: [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.1, 0.0, 0.3, 0.0,
  133. 0.0, 0.4, 0.0, 0.1, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0,
  134. 0.0, 0.6, 1.2, 1.7, 0.7, 2.9, 4.1, 2.6, 3.7, 3.9, 1.7, 2.3,
  135. 3.0, 3.3, 4.8, 5.0, 4.8, 5.0, 3.2, 2.0, 0.9, 0.4, 0.3, 0.5, 0.4]
  136. }]
  137. ,
  138. navigation: {
  139. menuItemStyle: {
  140. fontSize: '10px'
  141. }
  142. }
  143. });
  144. });
  145. </script>
  146. </head>
  147. <body>
  148. <script src="../../js/highcharts.js"></script>
  149. <script src="../../js/modules/exporting.js"></script>
  150. <div id="container" style="min-width: 310px; height: 400px; margin: 0 auto"></div>
  151. </body>
  152. </html>