Note: This is the code example of Jmail4.3, just sent success,
Sometimes the SMTP of 163 is wrong, I set it out with Outlook, and I have been hard for half a day yesterday.
Therefore, it is recommended to have a chance to apply for several mailboxes. When you test, you will not have trouble, don't doubt the code.
Added a database, directly read the information of the registered member, and then send Mail.
<%
DIM Conn
Set conn = server.createObject ("adoDb.connection")
Conn.open "provider = microsoft.jet.oledb.4.0; data source =" & server.mappath ("jmail.mdb")
%>
<% DIM RS
SET RS = Server.createObject ("AdoDb.Recordset")
SQL = "SELECT * from mymail1 where mailid = 1"
SET RS = Conn.execute (SQL)
%>
<%
Set jmail = server.createObject ("jmail.message") 'Establish an object that sends an email
Jmail.silent = True 'masked exception error, return false with true two value J
Jmail.logging = true 'Enables mail log
Jmail.Charset = "GB2312" message text code is national standard
Jmail.contentType = "text / html" 'ASD
Jmail.Priority = 3 'mail format is HTML
Jmail.addrecipient "yanmly@sina.com.cn" 'A to send mailbox
Jmail.mailServerUserName = "yanmly" 'b Your user name
Jmail.mailServerPassword = "xxxxxx" 'c your password
Jmail.From = "sogonew@gmail.com" 'sender's e-mail address
Jmail.fromname = "xie" 'sender's name
Jmail.subject = rs ("mailsubject") 'email headline
Jmail.body = ("mailcontent") 'email content
Jmail.send ("smtp.sina.com.cn") 'performing email transmission (via mail server address)
Jmail.close () 'Close object
%>
<% response.write RS ("mailcontent")%>
Related Resources: Jmail 4.4 Professional Edition