简体   繁体   中英

Add subject line in HTML

I'm trying to add a hyperlink using HTML. When a sender clicks a link, I would like the browser to create a new email with a filled out To field and subject line.

Code

HTML

<html>
  <head></head>
  <body>
    <p>Thank you.<br>
    <a href="mailto:aaa@company.com">test</a> 
    </p>
  </body>
</html>

You need to do the following:

<a href="mailto:aaa@company.com?subject=Testing out mailto!">test</a>

If you would like to add a BCC and CC, you can add the following:

<a href="mailto:aaa@company.com?subject=Testing email&bcc=bcc_email@gmail.com&cc=cc_email@gmail.com">test</a>

See more details on this method here .

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