Last Update : 2023-09-22 UTC 13:11:48 PM
Sender is set in headers,Sender is int the w3coded hosting email form of: sender
I used this little snippet to check it out:
<?php
error_reporting(E_ALL|E_STRICT);
ini_set('display_errors', 1);
echo 'I am : ' . `whoami`;
$result = mail('myaddress@mydomain.com','Testing 1 2 3','This is a test.');
echo '<hr>Result was: ' . ( $result === FALSE ? 'FALSE' : 'TRUE') . $result;
echo '<hr>';
echo phpinfo();
The solution was setting a value in my php.ini for 'sendmail_from' and 'sendmail_path'. The correct values in my case were:
sendmail_from = "no-reply@mydomain.net"
sendmail_path = "/usr/sbin/sendmail -t -i"
I found in php configuration file php.ini, I had set up
; For Win32 only.
;sendmail_from = me@example.com
; For Unix only.
sendmail_path = "/usr/sbin/sendmail -t -i -f "care@mydomain.com"
I have changed it to below
; For Win32 only.
;sendmail_from = me@example.com
; For Unix only.
sendmail_path = /usr/sbin/sendmail -t -i -f care@mydomain.com
Try setting the
ini_set('sendmail_from', $from);
Last Update : 2023-09-22 UTC 14:11:09 PM
Last Update : 2023-09-22 UTC 14:11:03 PM
Last Update : 2023-09-22 UTC 14:10:50 PM
Last Update : 2023-09-22 UTC 14:10:43 PM
Last Update : 2023-09-22 UTC 14:10:28 PM
Last Update : 2023-09-22 UTC 14:09:49 PM
Last Update : 2023-09-22 UTC 14:09:37 PM