JMail component uses Chinese documents

Source: Internet
Author: User

Jmail instructions

 

You can use the following functions in your asp program to send emails online:
The following functions are used to send a Message From a sender's mailbox, MailTo recipient, Subject topic, and Message:
FUNCTION Send_Mail (From, MailTo, Subject, Message)
Dim JMail, contentId, Domain, UserName, TextContent
Set JMail = Server. CreateObject ("JMail. Message ")
Domain = "211.157.100.145" 'valid email server address
UserName = "Sha Yang network" 'sender name
TextContent = "view in HTML format" 'text content
JMail. Charset = "gb2312" 'mail character set, "US-ASCII" by default"

'Sender information (assign values using variables)
JMail. From = From
JMail. FromName = UserName
JMail. Subject = Subject
'Set the priority, range from 1 to 5. The higher the priority, the higher the 3 is normal.
JMail. Priority = 3
JMail. AddHeader "Originating-IP", Request. ServerVariables ("REMOTE_ADDR ")
'Add one recipient [variable email: Recipient address] multiple recipients can be added in the same statement
JMail. AddRecipient (MailTo)
'Subject (HTML (note the attachment Link Method in the letter ))
JMail. HTMLBody = Message
'Subject (text part)
JMail. Body = TextContent
'Send [Call format: objJMail. Send ([username: password @] SMTPServerAddress [: Port])]
JMail. Send (Domain)
'Close and clear the object
JMail. Close ()
Set JMail = Nothing
END FUNCTION
'Here is the method to call this function, where the chen@8q8.net is the sender and the your@mail.com is the recipient
Call Send_Mail ("chen@8q8.net", "your@mail.com", "Test", "This is test mail! ")

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.