Despite having no function disabled and the setting Prevent "nobody" from sending mail disabled in the WHM Tweak settings, the mail is still not being sent from PHP when executed from Apache:
[root@cptechs ~]cPs# php -i | grep disable_function
disable_functions => no value => no value
Usually, there are no errors logged when this issue occurs.
This is caused by utilizing the
mod_mpm_itk Apache module. As mentioned in the following documentation:
The MPM ITK Apache module implements restrictions on the use of the
setuid() function and the
setgid() function. As a result, scripts that depend on these functions may encounter problems. This includes scripts that use the
mail() function, the
shell_exec function, or the
Choose a different MPM: Which MPM should I choose?