One Liner to test php sending mail from a bash script

To check if your php installation can successfully send emails from a bash script try this :

 php -r ‘var_dump(mail(“david.saliba@testemail.com”, “test subject”, “test body”));’

Thanks Gareth !

nJoy 🙂 !

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.