问题
This is my php code to send an email however it is not sending anything to my email
PHP
<?php
mail("nishil.shah17@gmail.com","PHP Mail Works!","Awesome","Hello");
?>
回答1:
The syntax is wrong You forgot to put @
correct syntax is
<?php
@mail("nishil.shah17@gmail.com","PHP Mail Works!","Awesome","Hello");
?>
and one more thing if you are using it on localhost than possible it won't work so you have to check it on remote server
来源:https://stackoverflow.com/questions/17737566/php-mail-not-sending-to-email