<!--#include file="../Include/Class_Conn.asp" -->
<!--#include file="../Include/Class_Main.asp" -->
<% 
Dim Action

Action = Request.QueryString("action")
If Action = "send" Then Call Send_Submit() '保存数据

 %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK href="../Css/Css.css" type=text/css rel=stylesheet>
<title><%= Cls_WebName %> -- 推荐职位给好友</title>
</head>
<script language="JavaScript">
			 function check(){
			  if(document.theForm.email.value==""){
			   alert("-请填写收件人的邮箱地址！-");
			   document.theForm.email.focus();
			   return false;
			  }
			  
			   if(document.theForm.email.value.indexOf(".")==-1 || document.theForm.email.value.indexOf("@")==-1){
			    alert("-邮箱地址不合法！-");
			    document.theForm.email.focus();
			    return false;
			   }
			  if(document.theForm.title.value==""){
			   alert("-请填写邮件标题！-");
			   document.theForm.title.focus();
			   return false;
			  }
			 }
			</script>

<body>
<table width="500" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td>&nbsp;</td>
  </tr>
</table>
<table width="470" border="0" align="center" cellpadding="0" cellspacing="0">
  <Form action="?action=send" method="post" name="theForm" onSubmit="return check();">
    <tr> 
      <td><table width="100%" border="0" cellpadding="2" cellspacing="1" bgcolor="eeeeee">
          <tr>
            <td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="eeeeee">
                <tr>
                  <td height="25" bgcolor="f9f9f9"> &nbsp;<img src="../Images/icon.gif" width="11" height="11" align="absmiddle"> 
                    <strong>推荐职位给好友</strong></td>
                </tr>
              </table>
              <table width="100%" border="0" cellspacing="1" cellpadding="0">
                <tr>
                  <td height="2"></td>
                </tr>
              </table>
              <table width="100%" border="0" cellspacing="1" cellpadding="0">
                <tr bgcolor="#FFFFFF"> 
                  <td width="100" height="25" align="right">好友邮箱地址：</td>
                  <td height="25"><input name="email" type="text" id="email" size="40" maxlength="50"></td>
                </tr>
                <tr bgcolor="f9f9f9"> 
                  <td width="100" height="25" align="right">邮件标题：</td>
                  <td height="25"> 
                    <input name="title" type="text" id="title" size="40" maxlength="50"></td>
                </tr>
                <tr bgcolor="#FFFFFF"> 
                  <td width="100" height="25" align="right">内 容：</td>
                  <td height="25"> 
                    <textarea name="memo" cols="40" rows="8" id="memo"></textarea></td>
                </tr>
              </table></td>
          </tr>
        </table></td>
    </tr>
    <tr>
      <td height="40" align="center"> 
        <input type="submit" name="Submit" value="发 送" style="height:30px;">
        <input type="button" name="Submit2" value="取消" style="height:30px;" onClick="window.close();">
      </td>
    </tr>
  </Form>
</table>
</body>
</html>
<% 
Sub Send_Submit() '发送邮件 
 Email = Request.Form("Email")
 Title = Request.Form("Title")
 Memo  = Request.Form("Memo")
 
 Call SendEmail(Email,Memo,Title)
 
 Response.write "<script language=JavaScript>alert('发送成功！');window.close();</script>"

End Sub

'//关闭数据库连接
CloseDB
 %>
