
- HTML Tutorial
- HTML - Home
- HTML - Overview
- HTML - Basic Tags
- HTML - Elements
- HTML - Attributes
- HTML - Formatting
- HTML - Phrase Tags
- HTML - Meta Tags
- HTML - Comments
- HTML - Images
- HTML - Tables
- HTML - Lists
- HTML - Text Links
- HTML - Image Links
- HTML - Email Links
- HTML - Frames
- HTML - Iframes
- HTML - Blocks
- HTML - Backgrounds
- HTML - Colors
- HTML - Fonts
- HTML - Forms
- HTML - Embed Multimedia
- HTML - Marquees
- HTML - Header
- HTML - Style Sheet
- HTML - Javascript
- HTML - Layouts
- HTML References
- HTML - Tags Reference
- HTML - Attributes Reference
- HTML - Events Reference
- HTML - Fonts Reference
- HTML - ASCII Codes
- ASCII Table Lookup
- HTML - Color Names
- HTML - Entities
- HTML - Fonts Ref
- HTML - Events Ref
- MIME Media Types
- HTML - URL Encoding
- Language ISO Codes
- HTML - Character Encodings
- HTML - Deprecated Tags
How do we send an email using HTML forms?
To send an email using HTML forms, you need to add the email id to the action attribute of the form. In that, add email proceeding with mailto: i.e. mailto:emailid@example.com.
Example
You can try to run the following code to send an email using HTML forms −
<!DOCTYPE html> <html> <body> <h2>Student Contact Form</h2> <form action="mailto:emailid@example.com" method="post" enctype="text/plain"> Student Name:<br><input type="text" name="sname"> <br> Student Subject:<br><input type="text" name="ssubject"><br> <input type="submit" value="Send"> </form> </body> </html>
- Related Articles
- How to send HTML email using Android App?
- How to send HTML email using Android App using Kotlin?
- How to send an attachment in email using Swift?
- How to send a html based email using a JSP page?
- How to send email using PowerShell?
- How to send an attachment in email using Swift(ios)?
- How do we upload external file on a website using HTML forms?
- Send email using Java Program
- How do we use radio buttons in HTML forms?
- How do we use checkbox buttons in HTML forms?
- How do we take password input in HTML forms?
- How to create a link to send email in HTML?
- How to send Email on Android using JavaMail API?
- How to send an email with a file attachment in Android using Kotlin?
- How do we reset all the input fields in HTML forms?

Advertisements