56 lines
2.2 KiB
HTML
56 lines
2.2 KiB
HTML
<!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>
|
||
function login(){
|
||
var account=document.getElementById("account").value
|
||
var pwd = document.getElementById("pwd").value
|
||
document.write(account+"的密码是:"+pwd)
|
||
console.log(account)
|
||
}
|
||
</script>
|
||
</head>
|
||
<body>
|
||
<!--
|
||
前后台分离
|
||
前台 后台(数据库 存储数据)
|
||
前台和后台通过 api(接口) 来联系
|
||
api 返回的格式
|
||
code 接口请求状态
|
||
data
|
||
msg 提示信息
|
||
form
|
||
表单 前台输入的信息 收集起来 ()传到后台 后台把信息存起来
|
||
action
|
||
-->
|
||
<!-- <form action="" method=""> -->
|
||
用户名 <input type="text" value="张三"><br />
|
||
密码 <input type="password" value="123"><br />
|
||
性别 <input type="radio" id="man" name="sex" checked="checked"> <label for="man">男</label>
|
||
<input type="radio" id="woman" name="sex" > <label for="woman">女</label> <br />
|
||
爱好 <input type="checkbox" id="mov"><label for="mov"> 看电影</label>
|
||
<input type="checkbox" id="game" checked="checked" > <label for="game">打游戏</label>
|
||
<input type="checkbox" id="music" checked="checked"><label for="music">听音乐</lable><br />
|
||
地址 <select name="" id="">
|
||
<option value="">济南</option>
|
||
<option value="" >泰安</option>
|
||
<option value="" >济宁</option>
|
||
<option value="">淄博</option>
|
||
<option value="">德州</option>
|
||
<option value="" selected="selected">西安</option>
|
||
</select><br />
|
||
<button onclick="alert('注册成功')">提交</button>
|
||
<!-- </form> -->
|
||
|
||
|
||
<div>
|
||
qq号:<input type="text" id="account" value=""> <br/>
|
||
密码: <input type="password" id="pwd" value=""><br/>
|
||
<button onclick="login()">登录</button>
|
||
</div>
|
||
</body>
|
||
</html> |