forked from halo-battle/game
Version 2007-11-04
This commit is contained in:
parent
4909921671
commit
ebc73c5744
377 changed files with 5163 additions and 2495 deletions
13
securitebanni.php
Normal file
13
securitebanni.php
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
<?php
|
||||
require('connectBDD.php');
|
||||
$ip = $_SERVER["REMOTE_ADDR"];
|
||||
$time = time();
|
||||
$req = mysql_query("SELECT * FROM banni WHERE `ip` = '$ip' AND `time` > '$time'");
|
||||
if (mysql_num_rows($req) > 0) { header('Location: index.php?erreur=b'); exit; }
|
||||
|
||||
if (isset($_SESSION['id'])) {
|
||||
$id = $_SESSION['id'];
|
||||
$req = mysql_query("SELECT * FROM banni WHERE `nom` = '$id' AND `time` < '$time'");
|
||||
if (mysql_num_rows($req) > 0) { header('Location: index.php?erreur=b'); exit; }
|
||||
}
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue