/usr/sbin/sendmail should be SUID root, if your isn't change that and it
should work fine.
Julia
Quoting Shrout, Ryan ([EMAIL PROTECTED]):
> I don't think that is it anymore. I have a new discovery. Upon running the
> actually PHP script from the console, the code works! But only when I am
> logged in as root. When logging is as anyone else, the mail() function
> fails with a Permission Denied on /usr/sbin/sendmail
>
> So, it would appear that sendmail is not configured to allow others to use
> it? Is there a quick easy way to fix this?
>
> Thanks!
>
> Ryan
>
> -----Original Message-----
> From: Michael Geier, CDM Systems Admin [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 10:57 AM
> To: Shrout, Ryan
> Subject: RE: [PHP] mail function fails
>
>
> RPM's tend to hose installations. May I suggest:
> rpm -qa | grep php
> rpm -e [insert php rpm name here]
> rpm -e [apache rpm]
>
> get the source for apache 1.3.20 (http://www.apache.org)
> get the source for php and compile per installation docs on php
> website
>
> You will enjoy the results alot more.
>
> -----Original Message-----
> From: Shrout, Ryan [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 9:46 AM
> To: 'Michael Geier, CDM Systems Admin'
> Subject: RE: [PHP] mail function fails
>
>
> Well, just using Red Hat 7.1 and sendmail with PHP 4.0.5. Sendmail was
> installed default in the RH installation, and then I installed the latest
> PHP RPM afterwards.
>
> Oh well.
>
> Ryan
>
> -----Original Message-----
> From: Michael Geier, CDM Systems Admin [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 10:45 AM
> To: Shrout, Ryan
> Subject: RE: [PHP] mail function fails
>
>
> Are you trying to use a MTA besides Sendmail?
>
> Some info would be helpful, such as:
> OS
> MTA (Sendmail Qmail, etc)
> PHP version
>
> If you installed PHP without sendmail installed, mail() will not work.
> That doesn't mean that you can't use a different MTA.
>
> When I switched to Qmail on a new server, a had a problem with mail()
> not working.
>
> I reinstalled OS (redhat 7.1) with sendmail, installed PHP (4.05),
> installed QMAIL per docs concerning replacing sendmail, changed
> php.ini file to reflect sendmail_path = /var/qmail/bin/qmail-inject.
>
> HTH
> ---
> Michael Geier
> CDM Sports, Inc. - Systems Administrator
> email: [EMAIL PROTECTED]
> phone: 314.991.1511 x 6505
> pager: 314.318.9414
>
> -----Original Message-----
> From: Shrout, Ryan [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 9:23 AM
> To: PHP Mailingliste
> Subject: RE: [PHP] mail function fails
>
>
> Darn, still didn't work.
>
> Anyone else have a suggestion? Or a way to view an error message of some
> kind?
>
> Ryan Shrout
>
> -----Original Message-----
> From: Tim Taubert [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 9:51 AM
> To: PHP Mailingliste
> Subject: RE: [PHP] mail function fails
>
>
> mh..
>
> <?php
> if (mail("[EMAIL PROTECTED]", "Quote Request", "test")) {
> echo "Email sent!";
> } else {
> echo "Email NOT sent!";
> }
> ?>
>
> this worked successfully... don't have any other ideas..
>
> bye tim
>
> ---------------------------------------------------------------------
> Tim Taubert | [EMAIL PROTECTED] | http://www.shogunat.com/rg/
> ---------------------------------------------------------------------
>
> -----Original Message-----
> From: Shrout, Ryan [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 3:30 PM
> To: PHP Mailingliste
> Subject: RE: [PHP] mail function fails
>
>
> I tried that in this format:
>
> if ( mail("[EMAIL PROTECTED]", "Quote Request", $message, "From:
> [EMAIL PROTECTED]\nX-Mailer: PHP/" . phpversion()) ) {
> echo "Email sent!";
> } else {
> echo "Email NOT sent!";
> }
>
> and still get the Email NOT sent and no emails go anywhere. Is there
> another solution? How about a way to get an error message of some kind?
>
> Ryan
>
> -----Original Message-----
> From: Tim Taubert [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 9:09 AM
> To: PHP Mailingliste
> Subject: RE: [PHP] mail function fails
>
>
> hey ryan try something like this
>
> mail("[EMAIL PROTECTED]", "Quote Request", $message, "From:
> [EMAIL PROTECTED]\nX-Mailer: PHP/" . phpversion());
>
> hope this helps
>
> cya tim
>
> ---------------------------------------------------------------------
> Tim Taubert | [EMAIL PROTECTED] | http://www.shogunat.com/rg/
> ---------------------------------------------------------------------
>
> -----Original Message-----
> From: Shrout, Ryan [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 02, 2001 3:01 PM
> To: '[EMAIL PROTECTED]'
> Subject: [PHP] mail function fails
>
>
> I am having a problem with the PHP mail() function. Here is the code:
>
> if (mail ("[EMAIL PROTECTED]", "Quote Request", $message)) {
> echo "Email sent!";
> } else {
> echo "Email NOT sent!";
> }
>
> Everytime, I receive the Email NOT sent message and the email isn't sent.
> However, from the console on the same machine, I can run the mail command:
> mail [EMAIL PROTECTED] and send an email just fine.
>
> Any ideas as to what could be wrong?
>
> I am using the latest PHP version and am running Red Hat Linux 7.1
>
> Ryan Shrout
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
--
[ Julia Anne Case ] [ Ships are safe inside the harbor, ]
[Programmer at large] [ but is that what ships are really for. ]
[ Admining Linux ] [ To thine own self be true. ]
[ Windows/WindowsNT ] [ Fair is where you take your cows to be judged. ]
PGP signature