How can I connect my contact form to send mail to my inbox

olalani profile image Olalani Oluwaseun ・1 min read

Hey Developers, recently I design a full website and host it but my contact form is not sending to my email inbox. Anytime a user fill the form and submit it Indicate "error 404". I seriously need more explanation and clarification on this. Thank you in anticipation.


markdown guide

It is very difficult to help you without some code examples. Probably you need to use a php file to send your email

404 means a wrong url. If you are using a PHP file(example.php) you need to submit your form data like this

Make sure that your input fields have a name attribute.

in your php file you can get the data like this
<?php $name = $_GET["name"]; ?>

in your php file you can send the email like this

mail("someone@example.com","My subject",$name);

Hope this helps


Whaooo you have just given me a clue of what to do. Thanks boss 👍 really appreciate it