Hi all,
Is anyone else struggling sending registration confirmation emails:
My code is below but I receive php.ini notices about smtp_port = 25.
Language: PHP
//Email registration confirmation
$to=$form_value[14];
$mailsent=mail($to,$subject,$emailmessage,$headers);
echo $mailsent ? "Mail Sent" : "Mail Failed";
if($mailsent){
$message=$message."<br>"."Email successfully sent to ".$to;
}
else{
$message=$message."<br>"."Registration Email Not Sent.";
}
So my questions are:-
- do we need to define config parameters in the config file?
- can emails work through gmail?
- is the code correct? Hope so.
Look forward to your assistance.
Cheers
Ian