I want my website to have the ability to send an email without refreshing the page. So I want to use Javascript.
<form action="javascript:sendMail();" name="pmForm" id="pmForm" method="post">
Enter Friend's Email:
<input name="pmSubject" id="pmSubject" type="text" maxlength="64" style="width:98%;" />
<input name="pmSubmit" type="submit" value="Invite" />
I want to call the function like this, but I have no idea what to put within the javascript code.
I discovered one example using the mailto technique in my study, but from what I can see, it doesn't really transmit from the website.
In order to send an email directly from a website, my question is where I can locate the code to insert within the JavaScript function.
function sendMail() {
/* ...code here... */
}