<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
    <meta name="apple-mobile-web-app-capable" content="yes"/>
    <meta name="apple-mobile-web-app-status-bar-style" content="black"/>
    <title></title>
    <script src="{{ theme }}/js/jquery.min.js"></script>
    <script src="{{ theme }}/js/jquery.validate.js"></script>
    <script src="{{ theme }}/js/public.js"></script>
    <script>
        $(document).ready(function () {
            $('#forgetForm').validate({
                rules: {
                    phone: {
                        required: true,
                        minlength: 11,
                        maxlength: 11
                    },
                    code: 'required',
                    password: 'required',
                    repeatPassword: {
                        required: true,
                        equalTo: '#password'
                    }
                },
                messages: {
                    phone: '请输入11位手机号',
                    code: '请输入验证码',
                    password: '请输入新密码',
                    repeatPassword: {
                        required: '请输入确认密码',
                        equalTo: '确认密码和新密码不匹配'
                    }
                }
            });
            sendCodeBindClick();
        });
    </script>
</head>
<body>
<form id="forgetForm" method="post">
    <p>
        <label for="phone">用户名<br>
            <input type="tel" name="phone" id="phone">
            <label id="phone-error" class="error" for="phone">{{ phoneError }}</label>
        </label>
    </p>

    <p>
        <label for="code">验证码<br>
            <input type="text" name="code" id="code">
            <label id="code-error" class="error" for="code">{{ codeError }}</label>
        </label>
        <span id="send">发送验证码</span>
    </p>

    <p>
        <label for="password">新密码<br>
            <input type="password" name="password" id="password">
            <label id="password-error" class="error" for="password">{{ passwordError }}</label>
        </label>
    </p>

    <p>
        <label for="repeatPassword">确认密码<br>
            <input type="password" name="repeatPassword" id="repeatPassword">
            <label id="repeatPassword-error" class="error" for="repeatPassword">{{ repeatPasswordError }}</label>
        </label>
    </p>

    <p class="submit">
        <input type="submit" id="register_submit" value="修改密码">
    </p>
</form>
</body>
</html>