regchk.php 1.2 KB

12345678910111213141516171819202122232425262728293031
  1. <?
  2. include("../config/conn.php");
  3. include("../config/function.php");
  4. $mob=$_GET[mob];
  5. if(strtolower($_SESSION["authnum_session"])!=strtolower($_GET[tpicyzm])){echo "err1";exit;}
  6. if(empty($mob)){echo "True";exit;}
  7. if(!empty($rowcontrol[smsbig])){
  8. $sj1=strtotime(date("Y-m-d H:i:s",strtotime("-1 day")));
  9. $sj2=strtotime(getsj());
  10. if(returncount("yjcode_smsmaillog where uip='".getuip()."' and admin=2 and sj>".$sj1." and sj<".$sj2."")>=$rowcontrol[smsbig]){echo "errbig";exit;}
  11. }
  12. intotable("yjcode_smsmaillog","admin,fa,userid,txt,sj,uip","2,'".$mob."',0,'直接登录验证',".strtotime(getsj()).",'".getuip()."'");
  13. while1("*","yjcode_smsmb where mybh='000'");
  14. if($row1=mysql_fetch_array($res1)){$txt=$row1[txt];}else{$txt="验证码:${yzm},如果不是本人操作,请忽略此信息。";}
  15. $yz=MakePass(6);
  16. if(empty($rowcontrol[smsmode])){
  17. include("../config/mobphp/mysendsms.php");
  18. $str=str_replace("\${yzm}",$yz,$txt);
  19. yjsendsms($mob,$str);
  20. }else{
  21. if(1==$rowcontrol[smsmode]){$sms_txt="{yzm:'".$yz."'}";}else{$sms_txt="{\"yzm\":\"".$yz."\"}";}
  22. $sms_mot=$mob;
  23. $sms_id=$row1[mbid];
  24. @include("../config/mobphp/mysendsms.php");
  25. }
  26. updatetable("yjcode_control","smskc=smskc-1");
  27. intotable("yjcode_yzm","tit,yzm,admin","'".$mob."','".$yz."',2");echo "ok";exit;
  28. ?>