当前位置:网站首页>Baidu Map Case - modify map style
Baidu Map Case - modify map style
2022-04-23 17:04:00 【Eli-sun】
https://lbsyun.baidu.com/apiconsole/custommap
Click... On this website Featured service platform - Personalized maps - Map template - Select a map style - Click publish style - Copy id Into the code
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<script type="text/javascript"
src="https://api.map.baidu.com/api?v=1.0&type=webgl&ak=cXG18I5SNt2EZNvG7CVyE4jjTr8swlo4"
></script>
<style>
html{
height: 100%;
height: 100%;
margin: 0;
padding: 0;
}
body{
height: 100%;
height: 100%;
margin: 0;
padding: 0;
}
#map{
height: 100%;
width: 100%;
margin: 0;
padding: 0;
}
.anchorBL, .BMap_cpyCtrl{
display: none;
}
</style>
</head>
<body>
<div id="map"></div>
<script>
console.log(window.BMapGL);
var map = new BMapGL.Map('map') // Initialize map
var point = new BMapGL.Point(116.404,39.915) // Set map coordinates
map.centerAndZoom(point, 10) // Central Map display level
map.enableScrollWheelZoom(true) // Zoom in and out of the map through the scroll wheel
// Custom map style
// You can also use styleJsion The way to change the style
map.setMapStyleV2({
styleId:'06649c73ab8ae3adffe6ea88ed400b23'
})
</script>
</body>
</html>
版权声明
本文为[Eli-sun]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230554289659.html
边栏推荐
- Variable length parameter__ VA_ ARGS__ Macro definitions for and logging
- Copy constructor shallow copy and deep copy
- Blue Bridge Cup provincial road 06 -- the second game of the 12th provincial competition
- Customize my_ Strcpy and library strcpy [analog implementation of string related functions]
- Zhongang Mining: Fluorite Flotation Process
- Change the password after installing MySQL in Linux
- 聊一聊浏览器缓存控制
- groutine
- How does flash cache data in memory?
- 批量制造测试数据的思路,附源码
猜你喜欢

Detailed explanation of Niuke - Gloves

VLAN高级技术,VLAN聚合,超级Super VLAN ,Sub VLAN

Node access to Alipay open platform sandbox to achieve payment function

Pytorch: the pit between train mode and eval mode
![[PROJECT] small hat takeout (8)](/img/54/0187eeb637f4dcd4ad3969b00e2b77.png)
[PROJECT] small hat takeout (8)

Milvus 2.0 détails du système d'assurance de la qualité

Mock test

文件操作《二》(5000字总结篇)

Modify the test case name generated by DDT

1-1 NodeJS
随机推荐
Do you really understand the principle of code scanning login?
Bottom processing of stack memory in browser
BUG_ me
Detailed explanation of Milvus 2.0 quality assurance system
PostgreSQL column storage and row storage
Tencent resolves the address according to the IP address
Rtklib 2.4.3 source code Notes
An essay on the classical "tear down the wall in thinking"
【WPF绑定3】 ListView基础绑定和数据模板绑定
线性代数感悟之2
【题解】[SHOI2012] 随机树
True math problems in 1959 college entrance examination
正则过滤内网地址和网段
◰GL-着色器处理程序封装
Installing labellmg tutorial in Windows
Linux MySQL data timing dump
oracle 中快速获取表的列名列表
线性代数感悟之1
面试百分百问到的进程,你究竟了解多少
Generate random numbers with high quality and Gaussian distribution