【php开源代码栏目提醒】:网学会员在php开源代码频道为大家收集整理了getuserinfo.php提供大家参考,希望对大家有所帮助!
<?php
include_once("top.php");
?>
<table width="870" border="1" align="center" cellpadding="1" cellspacing="1" bordercolor="#FFFFFF" bgcolor="#6EBEC7">
<tr>
<td bgcolor="#FFFFFF" valign="top"><table width="850" height="10" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td></td>
</tr>
</table>
<table width="750" border="0" align="center" cellpadding="0" cellspacing="1">
<tr>
<td bgcolor="#FFFFFF" valign="top">
<table width="750" height="20" border="0" align="center" cellpadding="0" cellspacing="0" background="images/lt_15(2).jpg">
<tr><td height="2"></td></tr>
<tr>
<td width="740" class="a9"><div align="left"> 用户录入 版块</div></td>
<td width="160"></td>
</tr>
</table>
<table width="750" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td valign="top"><?php
$usernc=trim($_POST[usernc]);
if($usernc==""){
echo "<script>window.location.href='register.php';</script>";
exit;
}
$sql=my
sql_query("select usernc from tb_user where usernc='".$usernc."'",$conn);
$info=
mysql_fetch_array($sql);
if($info!=false){
?>
<table width="600" height="100" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><div align="center"><font color="#FF0000">对不起,您的用户名已被其他网友所占用,请重新选择!</font></div></td>
</tr>
<tr>
<td><div align="center">
<input name="button" type="button" onclick="window.location.href='register.php'" value="返回" />
</div></td>
</tr>
</table>
<?php
}else{
?>
<table width="630" border="0" align="center" cellpadding="0" cellspacing="0">
<script language="
JavaScript" type="text/javascript">
function chkinput(form){
if(form.truename.value==""){
alert("请填写您的真实!");
form.truename.select();
return(false);
}
if(form.sex.value==""){
alert("请选择您的性别!");
form.sex.focus();
return(false);
}
if(form.email.value=="")
{
alert("请输入E-mail地址!");
form.email.select();
return(false);
}
var i=form.email.value.indexOf("@");
var j=form.email.value.indexOf(".");
if((i<0)||(i-j>0)||(j<0))
{
alert("请输入正确的E-mail地址!");
form.email.select();
return(false);
}
if(form.tel.value==""){
alert("请填写联系电话!");
form.tel.select();
return(false);
}
if(form.yb.value==""){
alert("请填写邮编地址!");
form.yb.select();
return(false);
}
if(isNaN(form.yb.value)==true){
alert("邮编只能由数字组成!");
form.yb.select();
return(false);
}
if(form.yb.value.length!=6){
alert("邮编长度只能为6位!");
form.yb.select();
return(false);
}
if(form.qq.value==""){
alert("请填写您的QQ号码!");
form.qq.select();
return(false);
}
if(isNaN(form.qq.value)==true){
alert("QQ号只能由数字组成!");
form.qq.select();
return(false);
}
if(form.address.value==""){
alert("请填写您的联系地址!");
form.address.select();
return(false);
}
if(form.question.value==""){
alert("请选择找回密码
问题!");
form.question.focus();
return(false);
}
if(form.answer.value==""){
alert("请填写找会密码答案!");
form.answer.select();
return(false);
}
if(form.xym.value==""){
alert("请填写验证码!");
form.xym.select();
return(false);
}
return(true);
}
</script>
<form action="savereginfo.php" method="post" name="form1" id="form1" onsubmit="return chkinput(this)">
<tr>
<td height="30" colspan="3"><div align="center"><font color="#FF0000"><br>您已经成功的申请了本站的用户名:</font> <font color="#0000FF"><?php echo $_POST["usernc"]?></font> <font color="#FF0000">如果注册为本站的用户,您还应该填写以下信息!</font><br><br><font color="#0000FF">注意:以下
注册信息均为必添内容!</font></div></td>
</tr>
<tr>
<td width="107" height="30"><div align="center">真实:</div></td>
<td height="30" colspan="2">
<input type="text" name="truename" size="25" class="inputcss" /> </td>
</tr>
<tr>
<td height="30"><div align="center">性别:</div></td>
<td height="30" colspan="2">
<select name="sex" class="inputcss">
<option selected="selected" value="">请选择</option>
<option value="男">男</option>
<option value="女">女</option>
</select></td>
</tr>
<tr>
<td height="30"><div align="center">邮箱地址:</div></td>
<td height="30" colspan="2">
<input type="text" name="email" size="25" class="i