First: This is NO ADVERT FOR byet.host (a website). Second: I'm a bit of a noob when it comes to databases, mysql, etc.
Ok, so I've got a site with a contact form. When I run it in my XAMPP server, it works fine (I receive a mail with the info they typed in the form). But when I run it in my byet.host server, I don't receive a e-mail. Do I need to set up a database, or do anything else?
<?php
$n = $_POST['n'];
$e = $_POST['e'];
$m = $_POST['m'];
$to = "**@gmail.com";
$subject = "** message";
$headers = 'From: **@gmail.com';
$message = '
Client name: '.$n.'
Client e-mail: '.$e.'
Client message: '.$m.'
Contact and website hosting is done by **.
';
if (
mail($to, $subject, $message, $headers)
)
echo"<script>alert('Your message has been send succesfully!')</script>";
else
echo"<script>alert('ERROR. Please contact us on Instagram. Message not send.')</script>";
?>