中国地图
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>中国地图</title>
<script src="js/echarts.js" type="text/javascript"></script>
<script src="js/china.js" type="text/javascript"></script>
<script type="text/javascript">
window.onload = function() {
var chart = echarts.init(document.getElementById("main"));
chart.setOption({
series: [{
"type": "map",
"map": "china"
}]
});
};
</script>
</head>
<body>
<div id="main" style="width:1200px;height:666px;"></div>
</body>
</html>
世界地图
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>世界地图</title>
<script src="js/echarts.js" type="text/javascript"></script>
<script src="js/world.js" type="text/javascript"></script>
<script type="text/javascript">
window.onload = function() {
var chart = echarts.init(document.getElementById("main"));
chart.setOption({
series: [{
"type": "map",
"map": "world"
}]
});
};
</script>
</head>
<body>
<div id="main" style="width:1200px;height:666px;"></div>
</body>
</html>
标签:function,map,onload,地图,chart,init,世界地图,中国 From: https://blog.csdn.net/jsb2283939167/article/details/139605400