HTML5技术

网页热力图 heatmap js - GoneWithWind

字号+ 作者:H5之家 来源:博客园 2016-06-29 14:00 我要评论( )

HBuilder +js 实现网页热力图 废话不多说,上代码 111A Quick ExampleWith only a few lines of code you can create your own interactive web heatmap:heatmap ); geoFindMe() { ); navigator.geolocation){ ; 31 return ; 32 } success(position) { posit

HBuilder +js 实现网页热力图

 

废话不多说,上代码

111A Quick ExampleWith only a few lines of code you can create your own interactive web heatmap:heatmap ); geoFindMe() { ); navigator.geolocation){ ; 31 return; 32 } success(position) { position.coords.latitude; position.coords.longitude; ; Image(); ; 42 43 output.appendChild(img); 44 }; error() { ; 48 }; ; 51 52 navigator.geolocation.getCurrentPosition(success, error); 53 } () { 61 62 geoFindMe(); ); h337.create({ 66 container: ex1el 67 }); () { {}; []; ; ; ; ; ) { ; Math.max(max1, val); { w), h), 82 value: val 83 }; 84 datap1.push(d); 85 } max1; datap1; 88 89 heatmap3.setData(data1); 90 }; 91 refreshHeatmap1(); () { 94 refreshHeatmap1(); 95 }; 96 };

 代码中用到的 heatmap.min.js  请搜索 heatmap 下载

/*
* heatmap.js v2.0.0 | JavaScript Heatmap Library
*
* Copyright 2008-2014 Patrick Wied <heatmapjs@patrick-wied.at> - All rights reserved.
* Dual licensed under MIT and Beerware license
*
* :: 2014-08-05 01:42
*/

 

1.本站遵循行业规范,任何转载的稿件都会明确标注作者和来源;2.本站的原创文章,请转载时务必注明文章作者和来源,不尊重原创的行为我们将追究责任;3.作者投稿可能会经我们编辑修改或补充。

相关文章
  • 网页适应所有屏幕宽度 - 侧耳倾听一场梦

    网页适应所有屏幕宽度 - 侧耳倾听一场梦

    2017-04-22 10:00

  • 网页版扫雷游戏 - 季末的寂寞

    网页版扫雷游戏 - 季末的寂寞

    2017-04-21 13:00

  • 基于CSS的个人网页 - 汕大-吴广林

    基于CSS的个人网页 - 汕大-吴广林

    2017-04-21 12:00

  • 10个TWaver 网页3D可视化精彩案例 - twaver

    10个TWaver 网页3D可视化精彩案例 - twaver

    2016-12-13 18:02

网友点评
d