Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6348151
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T21:22:01+00:00 2026-05-24T21:22:01+00:00

Possible Duplicate: how to send email by using javascript or jquery How can I

  • 0

Possible Duplicate:
how to send email by using javascript or jquery

How can I send an email with JavaScript, that is able to be read by Gmail, Yahoo, etc.?

This is what I have:

<script language="javascript">

       function SendEmail()
       {
           var body = escape(document.Form.textfieldName.value +"\n"+document.Form.textfieldEmail.value +"\n"+document.Form.textfieldMessage.value);

    var sTo="testmail@mail.com";

           var subject = "This is SyntaxHelpSub";

                           window.location.href =
    "mailto:"+sTo+"?subject="+subject+"&body="+body;

               }
</script>

        <div class="formfields">Name: <input class="tbox" id="textfieldName" type="text">

         Email: <input class="tbox" id="textfieldEmail" type="text">

<br><br>

Message: <input class="tbox" id="textfieldMessage" type="text" style="width: 343px">
    </div>

<br>

<input type="button" value="Send!" onclick="SendEmail()" />
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T21:22:02+00:00Added an answer on May 24, 2026 at 9:22 pm

    If you really want to send an email via javascript, then you need a cooperating server process that you can make an ajax call to. The javascript ajax call will deliver the contents of the email to the server and the server will send out the actual email.

    Browser clients do not actually send emails. The mailto: functionality allows a browser to communicate with the user’s chosen email program to ask that program to send out an email on the user’s behalf. This functionality may or may not be present or working in any given browser – you have no way of knowing. For example, my wife uses Yahoo mail and mailto: links never work for her because there is no email client program on her computer to coordinate with the browser to send out an email. In my opinion, these days with so many web email clients, it is a bad idea to rely on mailto: functionality in a browser.

    If you don’t have your own server that can do this for you, then there are some services out there like http://wufoo.com that offer email sending services (some parts of free) and you could likely deliver to them via javascript/ajax. To use Wufoo in this way, you’d have to build a wufoo form the way wufoo expects it to work, include it in your page (it can be hidden), fill it in (it can stay hidden), then submit it via ajax and the wufoo servers would send out the email to your desired destination.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: How do you send email from a Java app using Gmail? How
Possible Duplicate: Passing two command parameters using a WPF binding I need that send
Possible Duplicate: Sending email in .NET through Gmail I want to send an email
Possible Duplicate: Sending HTML email from PHP Using PHP to send an email. I
Possible Duplicate: Sending email in .NET through Gmail Say I want to send an
Possible Duplicates: ASP.NET- Sending an e-mail how to send mail using C#? How can
Possible Duplicate: How to send an NSDictionary (or plist file) as NSData using GameKit
Possible Duplicate: Ajax, javascript send variable to another page, on click Hello, Lets say
Possible Duplicate: How to get all options of a select using Jquery? I have
Possible Duplicate: Sending email through Gmail SMTP server with C# I would like my

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.