redho home | products | services

Programming Forums


Community for Java, PHP, Perl C, ASP and Python programmers
Friday 03 September 2010 04:32

Ask your IT question here

problem with mail function


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


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
Enthusiastic Coder


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
Enthusiastic Coder


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
Enthusiastic Coder


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
Enthusiastic Coder


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
Enthusiastic Coder


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


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
Enthusiastic Coder


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


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
Enthusiastic Coder


Joined: 02 Jun 2006
Posts: 111
So I don't need an additional server with ssmtp
Reply with quote
 
Page 1 of 3 Goto page 1, 2, 3  Next
Post new topic   Reply to topic    Programming Forums -> PHP programming forum


Dubai Forums - Expat Help | Vegan Forum | Java Programming | 3d Design Resources | 3d Forum | 3D Jobs | 3D Textures | Paris Forum | Europe Forum
Dubai Classifieds | Dubai Property | Jobs in Dubai | Free London Classifieds | Jobs in London UK

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

Based on phpBB © 2001-2010 RedHo