Jump to content

mail() questions


Mudsaf
 Share

Recommended Posts

Im wondering how does this mail() function work. I got PHP script likewhile ($row = mysql_fetch_array($result2)) {mail($row['Sahkoposti'], 'New comment on websites', '$text');} 1. $row['Sahkoposti'] = Email2. 'Subject'3. text Im wondering does this email thing require SMTP service or some port open to work correctly.

Link to comment
Share on other sites

I think all you have to do is open the default SMTP port (which is 25) in order to work. At least that's the error i am getting when trying to send emails from my localserver.

Link to comment
Share on other sites

So how should i configure this?

[mail function]; For Win32 only.; http://php.net/smtpSMTP = localhost (Keep this to localhost or public adress?); http://php.net/smtp-portsmtp_port = 25 (Open port 25 UDP?); For Win32 only.; http://php.net/sendmail-from;sendmail_from = me@example.comsendmail_from = [email="staff@MYSITE.COM"]staff@MYSITE.COM[/email] (Any email for example staff@mywebsite.com or does it have to be some real email adress); For Unix only.  You may supply arguments as well (default: "sendmail -t -i").; http://php.net/sendmail-path;sendmail_path = (???)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...