How to send a mail in php with html table,I received an smtp port 25 error msg | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

How to send a mail in php with html table,I received an smtp port 25 error msg

16th Apr 2018, 4:59 PM
Hirishi
5 Answers
+ 1
Note, if you upload to a hosting service, it will probably work.
16th Apr 2018, 5:05 PM
Emma
+ 1
<?php $to = 'maryjane@email.com'; $subject = 'Marriage Proposal'; $message = 'Hi Jane, will you marry me?'; $from = 'peterparker@email.com'; // Sending email if(mail($to, $subject, $message)){ echo 'Your mail has been sent successfully.'; } else{ echo 'Unable to send email. Please try again.'; } ?>
16th Apr 2018, 5:41 PM
Amit Kumar Rana
Amit Kumar Rana - avatar
0
I actually tried this,but the same error occurs....
16th Apr 2018, 5:08 PM
Hirishi
0
You'll need to show your code then. Also check PHP logs. Again, this is why frameworks are better than coding this stuff yourself
16th Apr 2018, 5:40 PM
Emma