How do I make a form details get submitted to my Gmail without using PHP | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

How do I make a form details get submitted to my Gmail without using PHP

Forms

31st Oct 2020, 9:36 AM
GANTECH
GANTECH - avatar
6 Answers
+ 3
Try something like <form action="mailto:[email protected]" enctype="text/plain">...</form> (And for course replace with your email)
31st Oct 2020, 10:41 AM
Martín Stanicio
0
How can I implement it with the submit button
31st Oct 2020, 3:08 PM
GANTECH
GANTECH - avatar
0
It's not working yet
31st Oct 2020, 3:08 PM
GANTECH
GANTECH - avatar
0
Did you try it? It's just a normal form with the action attr set to "mailto:[email protected]" I was doing some research and I think the method="post" is not meant to be there (I'll correct my previous comment) I also recommend adding enctype="text/plain" And just as a reminder, don't use your main email address, you don't want any spam there. If you insist in using Gmail then create a new account and set it up so it resends all the emails to your main account (Benefits? Your main account is not public and if you ever get spam you can unlink that account and repeat the process with a new one). Preferably you should create an email address with the domain of the webpage ([email protected]); adding a hash to it is a good idea as it gives you the chance to delete it when you start receiving too much spam. I believe you can also configure it to resend everything to your main/personal email.
31st Oct 2020, 6:06 PM
Martín Stanicio
0
I tried it now but d form details are not getting submitted its just like am sending a new mail to someone
1st Nov 2020, 4:39 PM
GANTECH
GANTECH - avatar
0
Are you using SoloLearn playground or local files on your computer? If you are using the playground then I recommend you use actual files. Did you search for this before asking? There should be enough info.
1st Nov 2020, 4:44 PM
Martín Stanicio