在ASP中用EasyMailObject处理Exchange邮件源代码---发送邮件的界面(sendmail1.asp)
1
2'*************************************
3
4'这个文件是发送邮件或回复邮件的界面
5'作者:awayeah
6'邮箱:[email protected]
7
8'*************************************
9
10
11'取得回信地址
12replyaddr=Request.QueryString("addr")
13'取得要回邮件的主题
14replysubj=replace(Request.QueryString("subject"),"_",space(1))
1<script language="vbscript">
2sub CmdSubmit_onClick()
3if trim(frmsendmail.receive1.value)="" then
4alert ("尚未输入收件人地址,请输入!")
5frmsendmail.receive1.focus
6else
7frmsendmail.submit
8end if
9end sub
10</script>
1<html>
2<head>
3<meta content="zh-cn" http-equiv="Content-Language"/>
4<meta content="text/html; charset=utf-8" http-equiv="Content-Type"/>
5<meta content="Microsoft FrontPage 4.0" name="GENERATOR"/>
6<meta content="FrontPage.Editor.Document" name="ProgId"/>
7<title>发邮件</title>
8</head>
9<body bgcolor="#008080" text="#00FFFF">
10<div align="center" span="1">
11<form action="p_sendmail.asp" method="POST" name="frmsendmail">
12<table bgcolor="#800080" border="1" cellspacing="1" width="455">
13<tr>
14<td width="92">
15<p align="right"><b>发 件 人</b></p>
16</td>
17<td width="347"><input name="from" size="40" type="text"/></td>
18</tr>
19<tr>
20<td width="92"><b>发件人邮箱</b></td>
21<td width="347"><input name="fromaddr" size="40" type="text"/></td>
22</tr>
23</table>
24<table bgcolor="#000080" border="1" height="56" width="455">
25<tr>
26<td height="23" width="52">
27<p align="center"><b>收件人</b></p>
28</td>
29<td height="23" width="387">
30<p align="left"><input name="receive1" size="40" type="text" value="```
31=replyaddr
32```"/></p>
33</td>
34</tr>
35<tr>
36<td height="23" width="52">
37<p align="center"><b>主 题</b></p>
38</td>
39<td height="23" width="387">
40<p align="left"><input name="subject" size="40" type="text" value="```
41=replysubj
42```"/></p>
43</td>
44</tr>
45<tr>
46<td colspan="2" height="1" width="445">
47<table border="0" cellpadding="0" cellspacing="0" height="184" width="100%">
48<tr>
49<td height="178" width="8%">
50<p align="center"><b>内</b>
51<p align="center">
52<p align="center"><b>容</b>
53<p> </p></p></p></p></td>
54<td height="178" width="92%"><textarea cols="55" name="bodytext" rows="10" value="```
55=bodytext
56```"></textarea></td>
57</tr>
58</table>
59</td>
60<tr> <td width="52">
61<p align="center"><b>附 件</b></p>
62</td> <td width="387"><input name="att" size="20" type="file"/></td></tr>
63</tr></table>
64<p align="center"><input name="cmdSubmit" type="button" value="发送"/> <input name="B2" type="reset" value="全部重写"/></p>
65</form>
66</div>
67</body>
68</html>