Sending Emails through PHP

Bhullarz's Avatar
Skilled contributor
Hi all ! I need help in sending emails through PHP. I want to send email to my website users. I have got the email id of all the users in MySQL table. I am retrieving those one by one. But the problem is Mail function of PHP is not sending mails to the users.
Code:
mail("Users' Email","subject of mail","content of mail","From:my email address");
I am using a free webhost which has enabled the php mail function for free users.

kindly guide me DO i need to setup anything extra for using this function. ?
How can I use my GOOGLE account to sending mails through PHP ?

Thanks in advance.
0
XXxxImmortalxxXX's Avatar
Invasive contributor
ill post the e-mail script i use for my domain in a hour or two okay
0
Bhullarz's Avatar
Skilled contributor
Quote:
Originally Posted by XXxxImmortalxxXX
ill post the e-mail script i use for my domain in a hour or two okay

I am waiting bro ! IT's been 2 days already.
0
XXxxImmortalxxXX's Avatar
Invasive contributor
yeah sry i had to reupload my webiste
0
Bhullarz's Avatar
Skilled contributor
Is there anyone else, who can provide the solution ?
0
pradeep's Avatar, Join Date: Apr 2005
Team Leader
You'll need to use SMTP to send email to people using your GMail id. Check out this PEAR Package Net_SMTP http://pear.php.net/manual/en/packag...smtp.intro.php
0
Lucysmith's Avatar, Join Date: Sep 2008
Newbie Member
goto w3schools.com, yu will find your answer there