$exec1 = "select count(*) as num from accounts where tgip='".$tgip."' and tgip<>'' ";
$result1 = $db->query($exec1);
$rs1 = $db->get($result1);
if ($rs1['num']>=$reg_num) {
echo "<script>alert('该IP地址已经注册太多次!');history.go(-1);</script>";
exit;
}
第二段:
$exec1 = "select count(*) as num from accounts where tgip='".$tgip."' and tgip<>'' ";
$result1 = $db->query($exec1);
$rs1 = $db->get($result1);
if ($rs1['num']>=$reg_num) {
echo "<b>该IP地址已经注册太多次</b>";
echo "<br><br><input type='button' class='btnFont' onclick='history.go(-1)' value=' 返 回 ' />";
exit;
}