I have the same script set up in my public_html and my private_html folders.
The script works only when called from the public_html folder. (ie: http://domain.com/mail.php)
It does NOT work if I call it from the private_html folder. (ie: https://domain.com/mail.php)
Does anyone know what is the reason for this? I need to have ability to send mail from a php script in the "secure" site area...
!!!!
Thanks.
PHP:
$msg = "This is a test.";
$mailheaders = "From: [email][email protected][/email]\r\n";
mail("[email protected]","Testing123", $msg, $mailheaders);
The script works only when called from the public_html folder. (ie: http://domain.com/mail.php)
It does NOT work if I call it from the private_html folder. (ie: https://domain.com/mail.php)
Does anyone know what is the reason for this? I need to have ability to send mail from a php script in the "secure" site area...
!!!!
Thanks.