ID:               28454
 Updated by:       [EMAIL PROTECTED]
 Reported By:      bugs dot php dot net at phoenixdigital dot com
-Status:           Open
+Status:           Bogus
 Bug Type:         Documentation problem
 Operating System: Freebsd 4.9 Stable
 PHP Version:      4.3.4
 New Comment:

It can be set in httpd.conf, just not in a virtual host setting.


Previous Comments:
------------------------------------------------------------------------

[2004-05-20 12:35:35] bugs dot php dot net at phoenixdigital dot com

Also you said I can't set in in .htaccess I am not being picky but I
did state that I am trying to set it in the httpd.conf which is
completely different.

------------------------------------------------------------------------

[2004-05-20 12:33:27] bugs dot php dot net at phoenixdigital dot com

Then this is a documentation issue because on this page

http://au.php.net/ini_set

sendmail_path DEFAULT_SENDMAIL_PATH PHP_INI_SYSTEM 

where 
PHP_INI_SYSTEM 4 Entry can be set in php.ini or httpd.conf  

It claims you CAN set it in a httpd.conf NOT

------------------------------------------------------------------------

[2004-05-20 12:26:45] [EMAIL PROTECTED]

This is not a bug, but meant to work like this due to security reasons.
(Ie, we don't want people to be able to configure their own sendmail
path in .htaccess files).

The correct way of doing what you want is to use the php_admin_value
mail.force_extra_parameters setting, which is configurable per vhost..
unfortunately that only works in PHP 5 (dev).

If you are comfortable patching, you can apply the following patch to
php 4.3.6 (it should also apply to 4.3.4):

Index: main/main.c
===================================================================
RCS file: /repository/php-src/main/main.c,v
retrieving revision 1.512.2.53
diff -u -p -r1.512.2.53 main.c
--- main/main.c 9 Feb 2004 04:05:56 -0000       1.512.2.53
+++ main/main.c 20 May 2004 10:26:04 -0000
@@ -356,7 +356,7 @@ PHP_INI_BEGIN()
 #endif
        PHP_INI_ENTRY("precision",                                     
"14",           PHP_INI_ALL,            OnSetPrecision)
        PHP_INI_ENTRY("sendmail_from",                          NULL,  
        PHP_INI_ALL,            NULL)
-       PHP_INI_ENTRY("sendmail_path",  DEFAULT_SENDMAIL_PATH, 
PHP_INI_SYSTEM,         NULL)
+       PHP_INI_ENTRY("sendmail_path",  DEFAULT_SENDMAIL_PATH, 
PHP_INI_SYSTEM|PHP_INI_PERDIR,          NULL)
        PHP_INI_ENTRY("disable_functions",                      "",    
                PHP_INI_SYSTEM,         NULL)
        PHP_INI_ENTRY("disable_classes",                        "",    
                PHP_INI_SYSTEM,         NULL)


But make sure to use php_admin_value sendmail_path "your command"  so
that it can't be overridden from .htaccess files.

------------------------------------------------------------------------

[2004-05-20 09:08:44] bugs dot php dot net at phoenixdigital dot com

if possible can you please adjust the email address in my bug report to
be a non real domain as I don't want my email to be trawled from this
bug report.

please change it to
php_value sendmail_path '/usr/sbin/sendmail -t -i -f
[EMAIL PROTECTED]'


Thanks

------------------------------------------------------------------------

[2004-05-20 09:04:22] bugs dot php dot net at phoenixdigital dot com

Description:
------------
Hi,

We are having trouble getting emails sent from php to set the
return-path header in messages. This is important as we host many sites
from our servers and want bounces to go to the hosted sites address
rather than our system address.

adding this line to the virtual host section in the apache conf.

php_value sendmail_path '/usr/sbin/sendmail -t -i -f
[EMAIL PROTECTED]'

then checking the a page with phpinfo() in it the change is not
visible.

We can set this value in the php.ini file perfectly but however we
cannot set it on a site by site basis in the virtual hosts directive.




------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=28454&edit=1

Reply via email to