案例说明:
通过正则表达式来对获取的内容进行判断
运行结果:
代码如下:
<html>
<head>
<meta charset="utf-8">
<title></title>
<style>
.box {
width: 700px;
height: 500px;
border:1px solid red;
margin: 0 auto;
padding: 100px 100px 0px;
}
p {
color: #5E5E5E;
}
p input {
margin-left: 10px;
width: 170px;
height: 25px;
border: 2px solid #ccc;
}
p button{
width: 150px;height: 40px;
margin-top: 20px;
border: none;
background-color: #FF6600;
color: #fff;
}
p span{
margin-left: 15px;
}
p img{width: 30px;height: 30px;position: relative; left: 10px;top: 10px;}
</style>
</head>
<body>