分类:
2006-08-24 16:40:56
$query_ip="SELECT * FROM user where ip='".$_POST["newip"]."' order by id";
$result_ip=mysql_query($query_ip); $row_ip = mysql_fetch_row($result_ip); if(!empty($row_ip)) { header("location:./error.php?info=IP exist! Please choose another!"); exit(1); } $query_name="SELECT * FROM user where name='".$_POST["newname"]."' order by id"; $result_name = mysql_query($query_name); $row_name = mysql_fetch_row($result_name) ; if(!empty($row_name)) { header("location:./error.php?info=User name exist! Please choose another!"); exit(1); } |
session_start();
session_register("user"); $user=$_POST["newname"]; header("Location:index.php"); |