php mail success code example
Example: php mail success message
if(mail($ToEmail, $EmailSubject, $MESSAGE_BODY, $mailheader))
{
echo "<script>document.location.href='contact.php'</script>";
}
else
{
echo "<script>alert('Mail was not sent. Please try again later');</script>";
}
}