Qmail question... configuring php.ini

They have: 33 posts

Joined: Oct 2003

Don't know if anyone can help me out or not?

I have a server that is using qmail on a Redhat 9 box for a while now and everything works great.

I don't have sendmail installed on my box at all.

My issue is when I try to use the php mail fuction it does not work.

I looked into my php.ini and I noticed a section for mail

Quote: [mail function]
; For Win32 only.
SMTP = localhost

; For Win32 only.
sendmail_from = [email protected]

; For Unix only. You may supply arguments as well (default: "sendmail -t -i").
sendmail_path = /usr/sbin/sendmail -t -i

So it looks as if my php.ini is still setup to use sendmail....

What is the proper synatax to use qmail?

I have tested my scripts on a server using sendmail and they work fine looks as if there is just a configuration issue with php.ini which I just don't know proper syantax to fix.

Thanks in advance.

James...

James

s0da's picture

He has: 157 posts

Joined: Mar 2004

Quote: sendmail_path
Where the sendmail program can be found, usually /usr/sbin/sendmail or /usr/lib/sendmail. configure does an honest attempt of locating this one for you and set a default, but if it fails, you can set it here.

Systems not using sendmail should set this directive to the sendmail wrapper/replacement their mail system offers, if any. For example, Qmail users can normally set it to /var/qmail/bin/sendmail or /var/qmail/bin/qmail-inject.

qmail-inject does not require any option to process mail correctly.

Links:
http://www.php.net/mail
http://www.qmail.org/
http://www.zend.com/manual/ref.mail.php

mairving's picture

They have: 2,256 posts

Joined: Feb 2001

Usually qmail would create a symlink at /usr/sbin/sendmail that goes to one of the two var locations that s0da listed above. RH has a tendency to install sendmail by default even if you tell it not to. Setting it to to proper var path should get it to work.

Mark Irving
I have a mind like a steel trap; it is rusty and illegal in 47 states

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.