📅  最后修改于: 2023-12-03 14:54:03.191000             🧑  作者: Mango
HTML中的mailto链接可以允许你从网页上方便地发送电子邮件。在这个链接中,你可以包含内容,以帮助用户准确地填写电子邮件内容。
下面的代码片段显示了如何使用mailto链接并带有一些内容:
<a href="mailto:example@example.com?subject=Mail%20from%20Website&body=Hello%20there!">Send Email</a>
实际上,该代码段中包含以下参数:
下面是一个实际场景的使用示例:
<a href="mailto:support@example.com?subject=Question%20about%20Your%20Product&body=Hello%20Support,%0A%0AI%20have%20a%20question%20about%20your%20product.%20Can%20you%20please%20provide%20me%20with%20additional%20information?%0A%0AThank%20you,%0AJohn">Contact Support</a>
这将打开电子邮件客户端,将收件人设置为"support@example.com",主题为"Question about Your Product",正文为:
Hello Support,
I have a question about your product. Can you please provide me with additional information?
Thank you,
John