Beispiel #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            Response.Clear();
            string result = "";

            if (Request.RequestType == "GET" || Request.RequestType == "POST")
            {
                string phone = Request.QueryString["phone"];
                if (phone == null)
                {
                    result = "phoneError";
                    Response.Write(result);
                    return;
                }
                string code = Request.QueryString["code"];
                if (code == null)
                {
                    result = "codeError";
                    Response.Write(result);
                    return;
                }
                string type = Request.QueryString["type"];
                if (type == null)
                {
                    result = "typeError";
                    Response.Write(result);
                    return;
                }

                SetUPInfo info = new SetUPInfo();

                string fmt = "";
                if (type == "0")
                {
                    fmt = WebConfigurationManager.AppSettings["bind_info"];
                }
                else if (type == "1")
                {
                    fmt = WebConfigurationManager.AppSettings["safeBoxInfo"];
                }
                else if (type == "2")
                {
                    fmt = WebConfigurationManager.AppSettings["relive_info"];
                }
                else
                {
                    result = "typeError";
                    Response.Write(result);
                    return;
                }

                string retstr = PhoneCom.sendCheckInfo(phone, code, fmt);
                Response.Write(retstr);
            }
            else
            {
                Response.Write(result);
            }
        }
Beispiel #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            Response.Clear();
            string result = "";

            if (Request.RequestType == "GET" || Request.RequestType == "POST")
            {
                string phone = Request.QueryString["phone"];
                if (phone == null)
                {
                    result = "phoneError";
                    Response.Write(result);
                    Response.Flush();
                    return;
                }

                string idList = Request.QueryString["serverId"];
                if (idList == null)
                {
                    result = "idError";
                    Response.Write(result);
                    Response.Flush();
                    return;
                }

                string msgInfo = Request.QueryString["msgInfo"];
                if (msgInfo == null)
                {
                    result = "msgError";
                    Response.Write(result);
                    Response.Flush();
                    return;
                }
                string retstr = PhoneCom.sendMonitorInfo(phone, idList, idList);
                Response.Write(retstr);
            }
            else
            {
                Response.Write(result);
            }
            Response.Flush();
        }
 // 向手机phone发送验证码code
 private string sendMsgToPhone(string phone, string account)
 {
     return(PhoneCom.sendSearchAccount(phone, account));
 }
 string sendMsgToPhone(string phone, string pwdcode)
 {
     return(PhoneCom.sendPhoneCode(phone, pwdcode));
 }