当前位置: 首页>>代码示例>>PHP>>正文


PHP check::CheckEmailAddr方法代码示例

本文整理汇总了PHP中check::CheckEmailAddr方法的典型用法代码示例。如果您正苦于以下问题:PHP check::CheckEmailAddr方法的具体用法?PHP check::CheckEmailAddr怎么用?PHP check::CheckEmailAddr使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在check的用法示例。


在下文中一共展示了check::CheckEmailAddr方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: strpos

 if (empty($_POST['replymail'])) {
     $_POST['replymail'] = $arrMsmtp[$intSmtpKey]['replymail'];
 }
 if (empty($_POST['replyuname'])) {
     $_POST['replyuname'] = $arrMsmtp[$intSmtpKey]['replyuname'];
 }
 $mail->AddReplyTo($_POST['replymail'], $_POST['replyuname']);
 $mail->AltBody = 'To view the message, please use an HTML compatible email viewer!';
 // optional - MsgHTML will create an alternate automatically
 $intKey = 0;
 $_POST['intro'] = strpos($_POST['intro'], '\\r\\n') === false ? str_replace("<br>", "\r\n", $_POST['intro']) : $_POST['intro'];
 foreach ($arrEmail as $v) {
     if (empty($v)) {
         continue;
     }
     if (!check::CheckEmailAddr($v)) {
         continue;
     }
     if (!empty($_POST['linkurl'])) {
         $smtv = $v;
         $mycontent2 = file_get_contents($_POST['linkurl'] . "?email={$v}");
         $_POST['intro'] = $mycontent2;
     }
     //$_POST['intro'] = file_get_contents("http://5217u/usermoney/fanli.php?email={$v}");
     $objShared->set('emaillog', ++$intSendNum);
     $mail->MsgHTML($_POST['intro']);
     $mail->AddAddress($v, substr($v, 0, strpos($v, '@')));
     $intKey++;
     if ($intKey == $_POST['type_id']) {
         $intKey = 0;
         try {
开发者ID:TiMoChao,项目名称:xingfu,代码行数:31,代码来源:email_sender.php

示例2: user

require_once 'config/config.inc.php';
require_once "class/user.class.php";
$objWebInit = new user();
//数据库连接参数
$objWebInit->setDBG($arrGPdoDB);
$objWebInit->db();
//smarty参数
$objWebInit->arrGSmarty = $arrGSmarty;
if ($_SERVER["REQUEST_METHOD"] == "POST") {
    if (empty($_POST['user_name'])) {
        check::AlertExit('对不起,用户名必须填写!', -1);
    }
    if (empty($_POST['email'])) {
        check::AlertExit('对不起,电子邮箱必须填写!', -1);
    }
    if (!check::CheckEmailAddr($_POST['email'])) {
        check::AlertExit('电子邮件格式不合法!', -1);
    }
}
if (!empty($_POST)) {
    $arrPost = array($_POST['user_name']);
    if ($arrUserInfo = $objWebInit->getUserWhere("where user_name=? and structon_tb like '%{$_POST['email']}%'", $arrPost)) {
        $arrMOutput["smarty_assign"]['password'] = $arrUserInfo[0]['password'];
    } else {
        check::AlertExit("错误:用户名或电子邮件不正确!", -1);
    }
}
if (!empty($arrUserInfo[0]['password'])) {
    $arrMOutput["smarty_assign"]['MAIN'] = $arrGSmarty['main_dir'] . 'getpassword.html';
} else {
    $arrMOutput["smarty_assign"]['MAIN'] = $arrGSmarty['main_dir'] . 'forgotten.html';
开发者ID:TiMoChao,项目名称:lc_ad_first,代码行数:31,代码来源:forgotten.php

示例3: userLogin

 /**
  * 会员登陆
  * @author	肖飞
  * @param	array $arrUser    会员信息数组
  * @return  void
  */
 public function userLogin($arrData, $isEncryption = 0, $jamStr, $isAlert = ture)
 {
     if (!check::CheckUser($arrData['User']) && !check::CheckEmailAddr($_POST['User']) && !check::CheckMobilePhone($_POST['User'])) {
         if ($isAlert) {
             check::AlertExit("输入的用户名必须是4-21字符之间的数字、字母,或7个中文!", -1);
         } else {
             return 0;
         }
     }
     if (!check::CheckPassword($arrData['Pass'])) {
         if ($isAlert) {
             check::AlertExit("输入的密码必须是4-21字符之间的数字、字母!", -1);
         }
         return 0;
     }
     $strPassTemp = $arrData['Pass'];
     if ($isEncryption) {
         $strPassTemp = check::strEncryption($strPassTemp, $jamStr);
     }
     $strUserName = $arrData['User'];
     if ($_SESSION['user_group'] == 3) {
         $strSQL = "SELECT * FROM {$this->tablename1} WHERE user_name = '" . $strUserName . "' and status=1";
         $rs = $this->db->query($strSQL);
     } else {
         $strSQL = "SELECT * FROM {$this->tablename1} WHERE user_name = '" . $strUserName . "' and password = '" . $strPassTemp . "' and status=1";
         $rs = $this->db->query($strSQL);
         if (!($arr = $rs->fetch(PDO::FETCH_ASSOC))) {
             $strSQL = "SELECT * FROM {$this->tablename1} WHERE email  = '" . $strUserName . "' and password = '" . $strPassTemp . "' and status=1";
             $rs = $this->db->query($strSQL);
             if (!($arr = $rs->fetch(PDO::FETCH_ASSOC))) {
                 $strSQL = "SELECT * FROM {$this->tablename1} WHERE mobile  = '" . $strUserName . "' and password = '" . $strPassTemp . "' and status=1";
                 $rs = $this->db->query($strSQL);
                 $arr = $rs->fetch(PDO::FETCH_ASSOC);
             }
         }
     }
     if ($arr) {
         if (is_array($_SESSION)) {
             $_SESSION = array_merge($_SESSION, $arr);
         } else {
             $_SESSION = $arr;
         }
         $arrUpdate = array();
         $arrUpdate['user_ip'] = check::getIP();
         $arrUpdate['lastlog'] = date('Y-m-d H:i:s');
         $arrUpdate['user_id'] = $arr['user_id'];
         $arrUpdate['logtimes'] = ++$arr['logtimes'];
         $arrUpdate['session_id'] = session_id();
         $this->updateUser($arrUpdate);
         return 1;
     } else {
         if ($isAlert) {
             check::AlertExit("用户名或密码错误", -1);
         } else {
             return 0;
         }
     }
 }
开发者ID:TiMoChao,项目名称:xingfu,代码行数:64,代码来源:mcenter.class.php


注:本文中的check::CheckEmailAddr方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。