Sending email via contact form

azdrian1837

New Member
Messages
4
Reaction score
0
Points
0
hello everyone,
I create a contact form on my website but the mail are not sending and am not getting any error could someone please help !! thank you.

here's my code

send.php:
Code:
<?php //send.php
require ('includes/config.inc.php'); 
$name = $_POST['name'];
$email = $_POST['email'];
$message = $_POST['message'];
$formcontent= "Name: $name /n Message: $message";
$recipent= "azdrian18@hotmail.com";
$subject= "Contact Form";
$mailheader="From: $email";
mail($recipent,$subject,$formcontent,$mailheader)or die("error in sending mail");
echo "thank you!";
?>

and the contact form:

Code:
<?php //contact.php
 $page_title ='Contact us'; 
 
include ('includes/header.html');
require ('includes/config.inc.php');
include ('includes/sidebar.php');
?>
<h1>Contact Page</h1>


<p>Quam, praesentium dignissim eros? Quis, saepe! Mollitia eiusmod nesciunt? Corrupti 
occaecati aptent, placeat omnis. Blanditiis mollit alias ipsum? Expedita pariatur.</p>


 <!-- Start of FORM -->
<form method="post" action="send.php">
<p>Name:<input type="text" name="name"/></p>
<p>Email:<input type="email" name="email"/></p>
<p>Message:</p><textarea name="message" rows="6" cols="25"></textarea><br/ >
 <input type="submit" name="send" value="submit"/>
</form>
<!-- End of FORM --> 
  


<?php include ('includes/footer.html'); ?>
 

misson

Community Paragon
Community Support
Messages
2,572
Reaction score
72
Points
48
Search first. There are a number of threads (some in the last few weeks) that cover this exact issue. Read over them and post back only if they don't resolve your problem.
 

azdrian1837

New Member
Messages
4
Reaction score
0
Points
0
i have already search through the forums but unfortunately i didn't find any post to help me find a solution:frown:
 
Top