<?php include("sql/conn.php"); 
session_start(); //开着身份验证，以后写
if (empty($_SESSION['yzm']))
{
exit;
}


$_GET['name'] = str_replace("<","",$_GET['name']);
$_GET['name'] = str_replace(">","",$_GET['name']);

$_GET['e'] = str_replace("<","",$_GET['e']);
$_GET['e'] = str_replace(">","",$_GET['e']);

$_GET['qq'] = str_replace("<","",$_GET['qq']);
$_GET['qq'] = str_replace(">","",$_GET['qq']);

$_GET['yzm1'] = str_replace("<","",$_GET['yzm1']);
$_GET['yzm1'] = str_replace(">","",$_GET['yzm1']);

$_GET['pass'] = str_replace("<","",$_GET['pass']);
$_GET['pass'] = str_replace(">","",$_GET['pass']);

$_GET['pass1'] = str_replace("<","",$_GET['pass1']);
$_GET['pass1'] = str_replace(">","",$_GET['pass1']);


?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title><?php include("adm/all/gjz.txt"); ?> 注册结果</title>
<meta name="description" content="<?php include("adm/all/description.txt"); ?> 注册结果" />
<meta name="keywords" content="<?php include("adm/all/gjz.txt"); ?> 注册结果" />
<link  href="css/css<?php include("adm/all/css.txt"); ?>.css" rel="stylesheet" type="text/css">
</head>

<body >
<div id="top">
<?php include("user.php");  ?>
</div>
<?php include("gh.php");  ?>
<div align="center">

<?php include("logo.php");  ?>

<div id="dh" ><?php 
 if(file_exists("dh1.php"))
 {
include("dh1.php"); 
 }
 else
 {
include("action/dh1.php"); 
 }
?></div>

</div>



<div align="center">
<div id="nr">

<?php
/////////////////////////////////////判断当中的获得系统主要数据！
$result = mysql_query("SELECT * FROM adm WHERE id='1'");
while($row = mysql_fetch_array($result))
  {
  $_SESSION['newr'] = $row['new'];///////////新人给几分·
  $msn = $row['msn'];///////////新人给几分·
  }
/////////////////////////////////////判断当中的获得系统主要数据！

$iipp = $_SERVER["REMOTE_ADDR"];
$noww = time();
?>


<?php include("ad/ad6.txt"); ?>

<br />

<style>
td{font-size:9pt;word-break: break-all}
.corner{font-size:0;}
.corner_bo{background:blue}
.corner_bg{background:#6699ff}
#tit{height:22px;color:white;}
#txt{line-height:150%;background:white;border:1px solid blue}
#tl,#tr,#bl,#br,#corner_tl,#corner_tr,#corner_bl,#corner_br{width:3px;height:3px}
#t,#b,#corner_t,#corner_b{height:3px}
#l,#r,#corner_l,#corner_r{width:3px}
</style>
<script src=corner.js></script>
<table cellpadding=0 cellspacing=0 width=400 align=center>
<tr><td id=tl></td><td id=t></td><td id=tr></td></tr>
<tr><td id=l></td>
<td id=box>
<table cellpadding=3 cellspacing=0 width=100%>
<tr id=tit><td>
<b>TTPK.NET免费发布 祝您心想事成！</b>
</td></tr>
<tr><td height=200 id=txt>
<p align="left">

<?php

echo "您刚才输入的内容为：<br />";
echo "用户名";
echo $_POST['name'];
echo "<br>电子邮件";
echo $_POST['e'];
echo "<br>";
echo "您当前使用的IP是".$iipp;
echo "<br>";

if ($_POST['name']=="")
{
	 echo "用户名为空，这可不行！<br>";
	 $zc="0";
}
if ($_POST['e']=="")
{
	 echo "邮件名不写，这可不行！<br>";
	 $zc="0";
}

	 $result = mysql_query("SELECT * FROM user where name ='".$_POST['name']."'");
	 if (mysql_num_rows($result) != 0)//检查库里是否有这个用户名
	 {
	 echo "这个用户名被人注册了，请您再选择其它用户名<br>";
	 $zc="0";
	 }
	 $result = mysql_query("SELECT * FROM user where e ='".$_POST['e']."'");
	 if (mysql_num_rows($result) != 0)//检查库里是否有这个邮箱
	 {
	 echo "这个邮箱被其它用户注册了！请您选择其它邮箱！<br>";
	 $zc="0";
	 }
	 $result = mysql_query("SELECT * FROM user where fip ='".$iipp."'");
	 if (mysql_num_rows($result) != 0)//检查库里是否有这个IP
	 {
	 echo "一个IP只能注册一个用户名，您的IP已经被使用了！<br>";
	 $zc="0";
	 }
	 if ($_SESSION['yzm1']!=$_POST['yzm1'])
	 {
	 echo "验证码出错了！<br>";
	 $zc="0";
	 }
	 if ($_POST['pass']!=$_POST['pass1'])
	 {
	 echo "两次密码不一样！<br>";
	 $zc="0";
	 }
	 
	 if ($zc=="0")
	 {
	 echo "[".$zc."]<strong>注册失败！</strong>";
	 }
	 else
	 {
	 echo "<strong>注册成功！</strong>新人赠送".$_SESSION['newr']."积分！";////注册成功写入几种数据！

$name = strip_tags ($_POST['name']); 
$name = str_replace(" ","",$name);

$e = strip_tags ($_POST['e']); 
$e = str_replace(" ","",$e);

$qq = strip_tags ($_POST['qq']); 
$qq = str_replace(" ","",$qq);

$msnnr = $msn;

mysql_query("INSERT INTO user (name,pass,e,fip,ft,jf,paty,qq) VALUES 
( '".$name."','".$_POST['pass']."','".$e."','".$iipp."','".$noww."','".$_SESSION['newr']."','0','".$qq."')");

mysql_query("INSERT INTO msn1 (nr, go1, gotime, to1, yd)
VALUES ('".$msnnr."', '管理员', '".$noww ."', '".$name."','0')");

mysql_query("INSERT INTO text (name, time, ip, ing, f) 
VALUES ('".$name."', '".$noww."', '".$iipp."', '注册', '+".$_SESSION['newr']."')");

	 }




?>

</p>
<Br>
</td></tr></table>
</td>
<td id=r></td>
</tr>
<tr><td id=bl></td><td id=b></td><td id=br></td></tr>
</table>
<script>
function setcorner(id)
{
var html;
if(id=="t")
{
html="<table class=corner id=corner_t cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bo></td></tr><tr><td class=corner_bg></td></tr><tr><td class=corner_bg></td></tr>"
html+="</table>"
}
if(id=="b")
{
html="<table class=corner id=corner_b cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bg></td></tr><tr><td class=corner_bg></td></tr><tr><td class=corner_bo></td></tr>"
html+="</table>"
}
if(id=="l")
{
html="<table class=corner id=corner_l cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bo></td><td class=corner_bg></td><td class=corner_bg></td></tr>"
html+="</table>"
}
if(id=="r")
{
html="<table class=corner id=corner_r cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bg></td><td class=corner_bg></td><td class=corner_bo></td></tr>"
html+="</table>"
}
if(id=="tl")
{
html="<table class=corner id=corner_tl cellpadding=0 cellspacing=0>"
html+="<tr><td bgcolor=white></td><td bgcolor=white></td><td class=corner_bo></td></tr>"
html+="<tr><td bgcolor=white></td><td class=corner_bo></td><td class=corner_bg></td></tr>"
html+="<tr><td class=corner_bo></td><td class=corner_bg></td><td class=corner_bg></td></tr>"
html+="</table>"
}
if(id=="tr")
{
html="<table class=corner id=corner_tr cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bo></td><td bgcolor=white></td><td bgcolor=white></td></tr>"
html+="<tr><td class=corner_bg></td><td class=corner_bo></td><td bgcolor=white></td></tr>"
html+="<tr><td class=corner_bg></td><td class=corner_bg></td><td class=corner_bo></td></tr>"
html+="</table>"
}
if(id=="bl")
{
html="<table class=corner id=corner_bl cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bo></td><td class=corner_bg></td><td class=corner_bg><td class=corner_bg></tr>"
html+="<tr><td bgcolor=white></td><td class=corner_bo></td><td class=corner_bg></td></tr>"
html+="<tr><td bgcolor=white></td><td bgcolor=white></td><td class=corner_bo></td></tr>"
html+="</table>"
}
if(id=="br")
{
html="<table class=corner id=corner_br cellpadding=0 cellspacing=0>"
html+="<tr><td class=corner_bg></td><td class=corner_bg></td><td class=corner_bo></td></tr>"
html+="<tr><td class=corner_bg></td><td class=corner_bo></td><td bgcolor=white></td></tr>"
html+="<tr><td class=corner_bo></td><td bgcolor=white></td><td bgcolor=white></td></tr>"
html+="</table>"
}
eval(id+".innerHTML=html")
}
function corner(border,bgcolor)
{
setcorner("tl")
setcorner("tr")
setcorner("bl")
setcorner("br")
setcorner("t")
setcorner("b")
setcorner("l")
setcorner("r")
corner_t.style.width=box.offsetWidth
corner_b.style.width=box.offsetWidth
corner_l.style.height=box.offsetHeight
corner_r.style.height=box.offsetHeight
box.style.background=bgcolor
}
corner("blue","#6699ff");
</script>





<?php include("ad/ad7.txt"); ?>




</div></div>
<?php 
 if(file_exists("foot.php"))
 {
include("foot.php"); 
 }
 else
 {
include("action/foot.php"); 
 }
?>

<?php include("sql/close.php");?>

</body>