简体   繁体   中英

Can I create a link in an email to automatically send an email populated with specific information from the original email?

I would like to create a link inside a "noreply@...com" email sent to a client with specific information, for the client to be able to click and automatically generate an email (mailto) using the information from the original noreply email.

Example:

From: noreply@example.com to: client1@gmail.com

Subject: Thank you for participating in yesterdays event!

Body: Thank you CLIENTNAME for participating in yesterdays EVENTNAME event! If you would like to confirm you attended click HERE.


I would to add a link in the HERE word to generate an autopopulated email that says: "Hi my name is CLIENTNAME, and i attended your EVENTNAME event"

**This is an example and I know it does nothing productive.

Yes you can create your link with a subject and body parameter.

 <a href="mailto:user@example.com?subject=Hello&body=This is my message">Email Us!</a>

You will need to escape any characters that might break the link... eg double quotes "

The mailto protocol is described in depth on MSDN pages. You can create a link in the email which can open a client's e-mail system and begins a new email message with a prepopulated fields.

sAddress

One or more valid e-mail addresses separated by a semicolon. You must use Internet-safe characters, such as %20 for the space character.

sHeaders

Optional. One or more name-value pairs. The first pair should be prefixed by a "?"and any additional pairs should be prefixed by a "&". The name can be one of the following strings.

  • subject

    Text to appear in the subject line of the message.

  • body

    Text to appear in the body of the message.

  • CC

    Addresses to be included in the "cc" (carbon copy) section of the message.

  • BCC

    Addresses to be included in the "bcc" (blind carbon copy) section of the message.

<a href="mailto:user@example.com?
    subject=MessageTitle&amp;
    body=Message Content">
    Contact Us</a>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM