Enable php default mail() in easyengine


#1

hi am new for server side and also easy php. am created 1 wordpress site with easyengine but mails are not sending. password reset and simple php mail code are also not working please help me :frowning:


#2

apt-get install sendmail


#3

ee stack install --mail


#4

He dont need the whole mail package, he needs the ability for php sending mails, without having a mailserver, nor webmail clients running there.

Sendmail fits more at this case.


#5

yes i want thats only…


#6

wowww, am tried many times this same command but not worked, now its working super… but its going on spam, is anyway to reach in inbox ???

Thank you ggloveswp ,portofacil


#7

There are maaany (really many) reasons that an email reaches spam instead of inbox. Googling around will help you for sure. Also, this tool will help you take proper actions: https://www.mail-tester.com/


#8

hi ggloveswp, if am give forget password in wordpress it working, but my simple php mail () function not working. plz help me. see the code

<?php $to = "mps.abi0001@gmail.com"; $subject = "HTML email"; $message = " HTML email

This email contains HTML Tags!

Firstname Lastname
John Doe
"; // Always set content-type when sending HTML email $headers = "MIME-Version: 1.0" . "\r\n"; $headers .= "Content-type:text/html;charset=UTF-8" . "\r\n"; // More headers $headers .= 'From: ' . "\r\n"; $headers .= 'Cc: mps.abi0001@gmail.com' . "\r\n"; if(mail($to,$subject,$message,$headers)){ echo "send"; } else{echo "failed";} ?>

i got send message. but in my inbox and spam nothing mail came…


#9

I didnt suggest creating a PHP sendmail file for troubleshooting.


#10

am installed the sendmail by running the command and now am make 1 php mail file to check.


#11

am uploaded the file in below link. page is working but i didn’t get mail after submitting. plz help me.

http://hirich.in/contact-form.php


#12

Use a transactional email service, like SparkPost, SendGrid for sending or install PHPMailer. Or if you want a complex solution try ZohoMail, etc. Mail() is not reliable and shouldn’t be used in production environment in my opinion.


#13

hi am tried php mailer but that also not working, please help me guys,


#14

Are the SMTP ports open in your firewall?


#15