Installing Pear mail

To send email with PHP through an SMTP account (e.g. Google Mail), it is easiest to install pear mail which can be done with the script below:

# Script to install pear mail so that one can send email via
# smtp (gmail) with the use of PHP.
# References http://www.markstechstuff.com/2009/04/installing-pear-mail-for-php-on-ubuntu.html
sudo apt-get install php-pear -y
sudo pear install mail
sudo pear install Net_SMTP
sudo pear install Auth_SASL
sudo pear install mail_mime

No comments:

Post a Comment