Home > Web Front-end > JS Tutorial > body text

Pure javascript to automatically send emails_javascript skills

WBOY
Release: 2016-05-16 15:35:50
Original
2318 people have browsed it

Description:

This JavaScript will help you email people. Just click email and there's someone! And the JavaScript will ask you for the email address, subject, etc. and then a new email will be opened to you.

<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function mailsome1(){
who=prompt("Enter recipient's email address: ","antispammer@earthling.net");
what=prompt("Enter the subject: ","none");
if (confirm("Are you sure you want to mail "+who+" with the subject of "+what+"&#63;")==true){
parent.location.href='mailto:'+who+'&#63;subject='+what+'';
  }
}
// End -->
</SCRIPT>
<a href='javascript:mailsome1()'>E-Mail Someone!</a>
<FORM>
<input type=button value="E-Mail Someone!" onClick="mailsome1()">
</FORM>
Copy after login

Okay, the above is the code to automatically send emails using javascript. The code is simple and easy to understand. I hope it will be helpful to everyone. For more information, please continue to pay attention to the Script House website. The site has new updates every day. The content has been updated, thank you!

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!