Answers for "send email code"

0

send email code

$to = '[email protected]'; $from = '[email protected]'; $fromName = 'Sender_Name';  $subject = "Send Text Email with PHP by CodexWorld";  $message = "First line of text\nSecond line of text";  // Additional headers $headers = 'From: '.$fromName.'<'.$from.'>';  // Send email if(mail($to, $subject, $message, $headers)){    echo 'Email has sent successfully.'; }else{    echo 'Email sending failed.'; }
Posted by: Guest on September-10-2021

Browse Popular Code Answers by Language