PHP: mail() function is not sending emails to GMAIL -
i have subscription form. simple! email input, that's it.
<input type="text" id="email" name="email" value=""> <button id="subscribe" type="button">subscribe</button>
what want php send email me (ej, myemail@gmail.com
), account gmail account, subscriber's email address message. simple!...or thought.
<?php $subscriber = filter_input(input_post, 'email'); /* send email */ $to = "myemail@gmail.com"; $subject = 'new subscriber'; $message = 'the following person wants subscribe: ' . "\r\n" . $subscriber; $headers = 'from: ' . $subscriber . "\r\n" . 'mime-version: 1.0' . "\r\n" . 'content-type: text/plain; charset=utf-8'; mail($to, $subject, $message, $headers); ?>
the php code works, when use email not gmail! can please me make work gmail?
Comments
Post a Comment