谁能教下我怎么使用ASP空间收信?
答案:2 悬赏:0 手机版
解决时间 2021-06-06 22:28
- 提问者网友:浩歌待明月
- 2021-06-06 00:17
会的各位友友来教我下,谢谢了!
最佳答案
- 五星知识达人网友:天凉才是好个秋
- 2021-06-06 01:34
收什么信 邮箱么
asp + JMAIL 收信功能
2009-09-23 13:17
<%@LANGUAGE="VBScript" CODEPAGE="936"%> <% Server.ScriptTimeout = 3600 %> <html> <head> <title>收取邮件</title> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> </head> <body bgcolor="#CCCCCC"> <bbody oncontextmenu="return false" bgcolor="#CCCCCC"> <table width="549" height="24" border="0" cellpadding="0" cellspacing="0" background="../images/002.png"> <tr> <td><font color="#FFFFFF"><strong> 收取邮件</strong></font></td> </tr> </table> <table width="549" height="400" border="1" cellpadding="0" cellspacing="0" bordercolorlight="#008080" bordercolordark="#FFFFFF"> <tr> <td valign="top" bgcolor="#FFFFFF"> <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td> <% myUser = "test3329@sohu.com" myPassword = "密码" myPop3 = "pop3.sohu.com" Set pop3 = Server.CreateObject( "JMail.POP3" ) pop3.Connect myUser, myPassword, myPop3 newnum=0 if pop3.count > 0 then for j=1 to pop3.count Set msg = pop3.Messages.item(j) ' Note the first element of this array is 1 ' since the POP3 server starts counting at 1 remail = "" ccmail = "" Set Recipients = msg.Recipients ' We now need to get all the recipients, ' both normal and Carbon Copy (CC) recipients ' and store them in a variabel For i = 0 To Recipients.Count - 1 Set re = Recipients.item(i) If re.ReType = 0 Then remail = remail & re.EMail & "," else ccmail = ccmail & re.EMail & "," End If Next topic=msg.Subject frommail=msg.From formname=msg.FromName Retime=msg.date msize=0 user_id=session("oid") if len(msg.htmlBody)>=10 then content=msg.htmlBody else content=msg.Body end if 'content=msg.Body&msg.htmlBody content=replace(content,"'","´") attech=getAttachments myMailHTML = "<hr />标题:" & topic & "<BR />" myMailHTML = myMailHTML & "发信者:" & frommail & "<BR />" myMailHTML = myMailHTML & "发信人:" & formname & "<BR />" myMailHTML = myMailHTML & "属性:" & attech & "<BR />" myMailHTML = myMailHTML & "时间:" & Retime & "<BR />" myMailHTML = myMailHTML & "大小:" & msize & "<BR />" myMailHTML = myMailHTML & "内容:" & content & "<BR />" myMailHTML = myMailHTML & "内容:" & remail & "<BR />" myMailHTML = myMailHTML & "内容:" & ccmail & "<BR />" myAllMailHTML = myMailHTML & myAllMailHTML next Response.Write myAllMailHTML ' if rs("copy_mail")<>"y" then ' pop3.DeleteMessages ' end if end if pop3.Disconnect %> </td> </tr> </table> </td> </tr> </table> </body> </html> <% function makefilename(fname) fname = now() fname = replace(fname,"-","") fname = replace(fname," ","") fname = replace(fname,":","") fname = replace(fname,"PM","") fname = replace(fname,"AM","") fname = replace(fname,"上午","") fname = replace(fname,"下午","") makefilename=fname end function function GetExtendName(FileName) dim ExtName ExtName = LCase(FileName) ExtName = mid(ExtName,instr(ExtName,".")+1) GetExtendName = ExtName end function Function getAttachments() Set Attachments = msg.Attachments getAttachments ="" For i = 0 To Attachments.Count - 1 Set at = Attachments(i) Dname=makefilename(now())&i&"."&GetExtendName(at.Name) url=server.MapPath("attech/")&""&Dname at.SaveToFile(url) conn.execute("insert into lsl_attech(ID,upname,msize,sdate) values('"&Dname&"','"&at.Name&"',"&at.Size&",'"& now &"')") getAttachments = getAttachments & Dname&"," Next End Function %> |
全部回答
- 1楼网友:神也偏爱
- 2021-06-06 02:00
1常来网免费空间(TheC.Cn) - 国内最大的免费空间站 ASP . FTP. PHP空间
【注册地址】:
http://web.99081.com/sysweb/RegTrans.aspx?CodeProvider=sky521 http://web.TheC.Cn/sysweb/RegTrans.aspx?CodeProvider=sky521
【特色介绍】:
『空间无限 永久免费』 免费为您提供无限大的存储空间,足以容纳成千上万甚至上百万计的网页文件,并可永久免费使用!
『域名绑定及转发』 您可以绑定(或转发)自己的域名,还可以将域名绑定(或转发)到子目录!另外赠送xxx.Qyun.Net的免费域名供您使用!
『WEB管理 FTP管理』 通过在线(Web)和FTP两种方式及在线解压/压解等强大功能,可以轻松完成网站发布及维护任务,使文件管理易如反掌!
『多种脚本支持』 支持HTML、ASP、ASP.NET1.0、ASP.NET2.0及PHP多种脚本,使您的选择更加灵活!
『数据库支持』 系统同进支持ACCESS、MSSQL、MYSQL三种数据库,使您的选更加全面,满足您的多种需要!
『组件齐全』 支持FSO、Zend、Jmail、AspJepg等多种流行组件,全面支持,并且不断完善,不断更新,体验更多建站乐趣! http://web.99081.com/sysweb/RegTrans.aspx?CodeProvider=sky521
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息
大家都在看
推荐资讯