<?
require"ygl.php";
$ynhead1="1";
$ynhead2="1";
include"header.php";
if($getpage=="mainpage")getpass();
if($get_pass!="")
   {
   if(empty($my_id)){errorview("请认真填写你的ID！");exit;}
   if(!file_exists("user/$my_id.php")){errorview("对不起，没有该用户！");exit;}
   else
       {
       read_user_zl($my_id);
       if(!empty($usermail))
           {
           $message=$user_id;
           $message.="你好：";
           $message.="你在时尚同学录注册时的密码是：".$userpass1;
           $mymail="ss_txl@21cn.com";
           mail($usermail,"取回时尚同学录注册时的密码",$message,"From: ".$mymail);
           errorview("你的密码已寄回你注册时所填的邮箱了！");exit;
           }else{errorview("对不起，你注册时没有填所箱，请和管理员联系！");exit;}
       }
   }
function getpass()
{
global $txlurl,$schooln,$classn,$mymail;
$title="取回密码";
$ynhead1="1";
print<<<EOT
<form name="form2" method="post" action="getpass.php">
 <table width="400" border="1" cellspacing="0" cellpadding="3" align="center"  bordercolorlight="#B5E1F7" bordercolordark="#FFFFFF">
  <tr>
   <td bgcolor="#B5E1F7" align="center"><b><font color="#000066">取回密码</font></b></td>
  </tr>
  <tr>
   <td>请输入你的ID：
    <input type="text" name="my_id" class=text>
   </td>
  </tr>
  <tr>
   <td align="center">
    <input type="submit" name="get_pass" value="提 交" class=text>
    <input type="reset" name="Submit4" value="重 置" class=text>
   </td>
  </tr>
 </table>
</form>
EOT;
}
include "footer.php";
?>