当前位置:网站首页>Basic case of Baidu map
Basic case of Baidu map
2022-04-23 17:03:00 【Eli-sun】
<script type="text/javascript"
src="https://api.map.baidu.com/api?v=1.0&type=webgl&ak=cXG18I5SNt2EZNvG7CVyE4jjTr8swlo4"
></script>
// This was introduced ak To apply for a Baidu map developer account , You can click in through the following website
https://lbsyun.baidu.com/index.php?title=jspopularGL/guide/helloworld
<!DOCTYPE html>
<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
</script>
</body>
</html>
版权声明
本文为[Eli-sun]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230554289813.html
边栏推荐
- Nodejs reads the local JSON file through require. Unexpected token / in JSON at position appears
- Linux MySQL data timing dump
- Website_ Collection
- 博士申请 | 厦门大学信息学院郭诗辉老师团队招收全奖博士/博后/实习生
- Nifi fast installation and file synchronization
- Smart doc + Torna generate interface document
- ◰ GL shadow map core steps
- 【PIMF】OpenHarmony啃论文俱乐部—在ACM Survey闲逛是什么体验
- JSON deserialize anonymous array / object
- Detailed explanation of Milvus 2.0 quality assurance system
猜你喜欢
信息摘要、数字签名、数字证书、对称加密与非对称加密详解
批量制造测试数据的思路,附源码
Use case execution of robot framework
Deepinv20 installation MariaDB
Path environment variable
How vscode compares the similarities and differences between two files
Pytorch: the pit between train mode and eval mode
RTKLIB 2.4.3源码笔记
On lambda powertools typescript
vscode如何比较两个文件的异同
随机推荐
Detailed explanation of Niuke - Gloves
freeCodeCamp----shape_ Calculator exercise
Document operation II (5000 word summary)
Log4j output log information to file
Paging the list collection
Kingdee Cloud Star API calling practice
Redis docker installation
Interface document yaml
【题解】[SHOI2012] 随机树
VsCode-Go
Project framework of robot framework
网络安全之渗透靶场实战详解
websocket
Nodejs reads the local JSON file through require. Unexpected token / in JSON at position appears
∑GL-透视投影矩阵的推导
Encapsulating the logging module
Nacos + aspnetcore + Ocelot actual combat code
Preliminary understanding of promse
1-3 nodejs installation list configuration and project environment
Pycham connects to the remote server and realizes remote debugging