12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
- <meta http-equiv="X-UA-Compatible" content="IE=edge" />
- <meta name="viewport" content="width=750, initial-scale=1, maximum-scale=1, user-scalable=0" />
- <meta name="keywords" content="" />
- <meta name="description" content="" />
- <title>新增</title>
- <!-- FAVICON AND APPLE TOUCH -->
- <link href="favicon.ico" rel="shortcut icon" />
- <link rel="apple-touch-icon-precomposed" sizes="180x180" />
- <meta name="msapplication-TileImage" content="mstile.png" />
- <link rel="stylesheet" href="css/common.css" />
- <meta name="viewport" content="width=375, user-scalable=no" />
- </head>
- <body>
- <div class="page-wrapper">
- <div class="fixed-section">
- <div class="nav-tit">
- <a class="goBack" onclick="history.back()"></a>
- 新增
- </div>
- </div>
- <form action="" style="margin-top:40px">
- <div>
- <span><i>*</i>站点名称:</span>
- <input type="text" name="siteName">
- </div>
- <div>
- <span><i>*</i>站点位置:</span>
- <input type="text" name="siteplace">
- </div>
- <div>
- <span><i>*</i>站点地址:</span>
- <input type="text" name="siteAddress">
- </div>
- <div>
- <span><i>*</i>联系人:</span>
- <input type="text" name="contactMan">
- </div>
- <div>
- <span><i>*</i>手机号码:</span>
- <input type="text" name="mobile">
- </div>
- <a class="submit-btn">提交</a>
- </form>
- </div>
- <script src="js/layout.js"></script>
- <script src="js/jquery-2.2.2.min.js"></script>
- <script>
- $('.submit-btn').click(function() {
- if ($('input[name=siteName]').val().length == 0) {
- alert('请输入站点名称')
- return false;
- }
- if ($('input[name=siteplace]').val().length == 0) {
- alert('请输入站点位置')
- return false;
- }
- if ($('input[name=siteAddress]').val().length == 0) {
- alert('请输入站点地址')
- return false;
- }
- if ($('input[name=contactMan]').val().length == 0) {
- alert('请输入联系人')
- return false;
- }
- var mobile = $('input[name=mobile]').val();
- if (mobile.length == 0) {
- alert('请填写手机号码');
- return false;
- } else {
- var telre = /^(13[0-9]|14[0-9]|15[0-9]|17[0-9]|18[0-9])\d{8}$/;
- if (!telre.test(mobile)) {
- alert('请输入有效的手机号码');
- return false;
- }
- }
- })
- </script>
- </body>
- </html>
|