I want to send email to entered email address. But I keep getting this error.
mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set()
This is my code
<?php
$email=$_POST["email"];
$message="Your application has been submitted tothe Incharge and Admin of the classes. Thanks for applying at our insitute.";
mail($email,"Confirm Application", $message, "From: anemade45@gmail.com");
?>
<form method="post">
<input type="email" name="email" placeholder="enter your email address">
</form>
What should I do to remove that error?