<%@ Page Language="C#" AutoEventWireup="true" CodeFile="reg.aspx.cs" Inherits="reg" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>注册成为海天一员</title>
    <LINK rel="stylesheet" type="text/css" href="style/m.min.css">
    <META content="text/html; charset=utf-8" http-equiv="Content-Type">
    <script src="jQuery/jquery-1.4.2.min.js" type="text/javascript"></script>
    <script src="jQuery/checkmobile.js" type="text/javascript"></script>
</head>
<body>

    <form id="form1" runat="server">
    <DIV id="header">
<TABLE>
  <TBODY>
  <TR>
    <TD><A href="http://edu.haitian.com.cn/m/"><IMG alt="海天集团"src="images/m-logo.gif"></A></TD></TR></TBODY></TABLE></DIV>
<P class="title">注册海天!</P>
<DIV class="content">
<FORM method="post" action="/m/signup">
<DIV>手机号：<BR>
<%--<INPUT id="mobile" name="mobile" maxLength="50" type="text" onkeyup="value=value.replace(/[^\d]/g,'')"><span style="display: none; color:Red;" id="msg_tel_err"> </span>--%>
<INPUT id="mobile" name="mobile" type="text" maxlength="11" onkeyup="value=value.replace(/[^\d]/g,'')"><span style="display: none; color:Red;" id="msg_tel_err"> </span>
<BR><SPAN class="note">仅支持标准手机号</SPAN></DIV>
<DIV>邮箱：<BR><INPUT name="password" type="text" id="email"></DIV>
<DIV><INPUT id="reg-user" class="button" name="sumbit" value="注册" type="button"></DIV></FORM></DIV>
<div class="subSuccess"></div>
<P class="link"><A href="Default.aspx"><<返回首页</A></P>

<DIV id="ft">海天集团 © 2011</DIV>
    </form>
    <script type="text/javascript" language="javascript">
        $(document).ready(function () {
            $("#reg-user").click(function () {
                var bol = checkTel();
                var _oReg = /^([a-zA-Z0-9]+[_|\_|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\_|\.]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/;
                var useremail = $("#email").val();
                if (!_oReg.test(useremail)) {
                    $(".subSuccess").html("<p style='color:Red'>邮箱格式不正确</p>");
                }
                else {
                    $.ajax({
                        type: "post",
                        url: "ashx/Addquestion.ashx?mode=reg&phone=" + $("#mobile").val() + "&email=" + $("#email").val() + "",
                        success: function (msg) {
                            $(".subSuccess").html("<p style='color:Red'>注册成功</p>");
                            
                        }
                    });
                }
            });
        });
    </script>
</body>
</html>