第二天
This commit is contained in:
27
02. 前端Web基础(JS+Vue+Ajax)/JS-Vue/14. Axios-入门.html
Normal file
27
02. 前端Web基础(JS+Vue+Ajax)/JS-Vue/14. Axios-入门.html
Normal file
@@ -0,0 +1,27 @@
|
||||
<!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>Ajax-Axios</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<input type="button" value="获取数据GET" id="btnGet">
|
||||
<input type="button" value="操作数据POST" id="btnPost">
|
||||
|
||||
<script src="js/axios.js"></script>
|
||||
<script>
|
||||
//发送GET请求
|
||||
document.querySelector('#btnGet').addEventListener('click', () => {
|
||||
|
||||
})
|
||||
|
||||
//发送POST请求
|
||||
document.querySelector('#btnPost').addEventListener('click', () => {
|
||||
|
||||
})
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user