How to disable PHP mail function on one apache virtualhost?
5,406
I added this to my virtual host:
<Directory /dir/to/your/web/root>
...
php_admin_value sendmail_path "tee mail.out > /dev/null"
...
</Directory>
It worked!
Related videos on Youtube
Author by
darkw1nd
Updated on September 18, 2022Comments
-
darkw1nd almost 2 years
I want to disable PHP function mail via Apache2 virtual host configuration file. I want to do it for one virtual host, not for all virtual hosts, and I don't want disable this function in php.ini
How to do it correctly?
Thanks in advance!
-
Brian Stinar about 5 yearsDid this work for you? I'm getting a apachectl configtest ... /main.conf error: Invalid command 'php_admin_value', perhaps misspelled or defined by a module not included in the server configuration