0

I'm trying to send a php mail for a very basic form, I receive the email of success but the email never arrives, or the received spam, nowhere. Here is the code

<?php
    $nombre = $_POST['name'];
    $email = $_POST['email'];
    $mensaje = $_POST['mensaje'];
    $para = 'me@example.com';
    $titulo = 'ASUNTO DEL MENSAJE';
    $header = 'From: ' . $email;
    $msjCorreo = "Nombre: $nombre\n E-Mail: $email\n Mensaje:\n $mensaje";

    if (mail($para, $titulo, $msjCorreo, $header)) {
    echo "<script language='javascript'>
            alert('Mensaje enviado, muchas gracias.');
            window.location.href = 'www.fullmecanic.com';
        </script>";
    } else {
        echo 'Falló el envio';
    }
?>

As previously name, I receive the message of success but does not email.

hateful
  • 141
  • 2
  • 13

0 Answers0