redho home | products | services
Web Design Forums

Web Design Forums  


Web Hosting, Web Design, Software and Web Development Forums  
 FAQFAQ   MemberlistArchive  Log inLog in   RegisterRegister 
         

problem with mail function


Goto page 1, 2  Next
 
Post new topic   Reply to topic    Web Design Forums -> PHP programming forum
View previous topic :: View next topic  
Author Message
Roombor



Joined: 02 Jun 2006
Posts: 111
I'm having problems with mail() and I'm pretty sure it is a lack of some config, what do I need to do to allow php to mail out?
  Reply with quote


WarChild



Joined: 24 Feb 2006
Posts: 46
It deppends of what OS are you using.
Also check out the relevant part of your php.ini
  Reply with quote
montanarry



Joined: 13 May 2006
Posts: 175
Have a local smtp-installation.
Which either means you need ssmtp and a smtp-server or a smtp-server on the php-running box.
In both cases you should have a "sendmail" command which is working. if you don't have, php can't send email (afaik)
  Reply with quote
Roombor



Joined: 02 Jun 2006
Posts: 111
:), I installed ssmtp, I kind of thumbled through the config of it, I was concerned with mailhub= var in the config. Am I right in thinking that you only need ssmpt and nothing else to send emails from php?
  Reply with quote
montanarry



Joined: 13 May 2006
Posts: 175
As long as you have a smtp-server running accepting mails from the php-running box (the one you installed ssmtp on) without further authentication and stuff - yes.
  Reply with quote
Roombor



Joined: 02 Jun 2006
Posts: 111
K, thx
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
Not really
You need to configure php a little differently for it to work with ssmtp
The default way it calls the mailer does not work with sendmail
  Reply with quote
Roombor



Joined: 02 Jun 2006
Posts: 111
Any recommendations for an smtp server?
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
If you jsut want to send mails, ssmtp is perfectly fine
Let me search the correct line to put in php.ini for it to work, just a moment
Sendmail_path = "/usr/sbin/ssmtp -t -i"
That's it :)
  Reply with quote
Roombor



Joined: 02 Jun 2006
Posts: 111
So I don't need an additional server with ssmtp
  Reply with quote
montanarry



Joined: 13 May 2006
Posts: 175
Roombor: i'm using postfix on my servers.
  Reply with quote


PaulKolin



Joined: 25 May 2006
Posts: 108
You can run it on the same server without problems (ssmtp)
This setup actually expects the ssmtp server to be on the same machine, as it's directly calling the binary
  Reply with quote
montanarry



Joined: 13 May 2006
Posts: 175
Roombor, if your provider lets you send mails without authentication to its smtp-servers, yes.
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
montanarry, ehmm with ssmtp you are your own smtp-server...
Ssmtp is full smtp server
Just with very little functionality besides sending mail out
  Reply with quote
montanarry



Joined: 13 May 2006
Posts: 175
PaulKolin, but no way to deliver mail to any mailbox.
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
No, it's only there to send mail, which is what an smtp server should only do
Delivering mail is the job of a MDA
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
Have a local smtp-installation.
Which either means you need ssmtp and a smtp-server or a smtp-server on the php-running box.
In both cases you should have a "sendmail" command which is working. if you don't have, php can't send email (afaik)
but you may try to get some processing time
  Reply with quote
ovigo22



Joined: 15 May 2006
Posts: 130
:), I installed ssmtp, I kind of thumbled through the config of it, I was concerned with mailhub= var in the config. Am I right in thinking that you only need ssmpt and nothing else to send emails from php?
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
As long as you have a smtp-server running accepting mails from the php-running box (the one you installed ssmtp on) without further authentication and stuff - yes.
  Reply with quote
ovigo22



Joined: 15 May 2006
Posts: 130
K, thx
  Reply with quote
Poolkop



Joined: 01 Jun 2006
Posts: 123
Not really
You need to configure php a little differently for it to work with ssmtp
The default way it calls the mailer does not work with sendmail
  Reply with quote


ovigo22



Joined: 15 May 2006
Posts: 130
Any recommendations for an smtp server?
  Reply with quote
Poolkop



Joined: 01 Jun 2006
Posts: 123
If you jsut want to send mails, ssmtp is perfectly fine
Let me search the correct line to put in php.ini for it to work, just a moment
Sendmail_path = "/usr/sbin/ssmtp -t -i"
That's it :)
  Reply with quote
ovigo22



Joined: 15 May 2006
Posts: 130
So I don't need an additional server with ssmtp
  Reply with quote
PaulKolin



Joined: 25 May 2006
Posts: 108
ovigo22, i'm using postfix on my servers.
  Reply with quote
Page 1 of 2 Goto page 1, 2  Next
Post new topic   Reply to topic    Web Design Forums -> PHP programming forum


Dubai Forums - Expat Help | Vegan Chat | Java Programming | Free 3D tutorials and 3d textures | Paris Forum | EU Forum
Free Dubai Classifieds | Free London Classifieds | Jobs in London

High Quality, Custom 3d animation and Web Design solutions Royal Quality Web Hosting Services Vegetarian and Animal Rights news

Powered by phpBB © 2001, 2005 phpBB Group