How to send Email using PHP with MySQL in Linux Server?..

Answer Posted / ks.tarun

u can send mail via php in linux with he help of linux
commands s well like..
<?php

$file = "test.txt";
system("echo -e 'Message Body' | mutt -s 'Subject' -a
test.txt email@email.com");
?>

that will send mail to the recipient with attachment of file.
for that u just have to install mutt rpm also
for that run below commands:

# yum -y install *mutt*

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is php artisan tinker?

505


Is server side a session?

496


Explain how we can get the number of elements in an array?

512


What is the array in php?

553


Is php a dying language?

530






What is a namespace in php?

471


Does php have block scope?

523


What is the maximum size of a table in mysql?

531


How can I find my php version?

537


Tell me how comfortable are you with writing html entirely by hand?

501


When to use get and post request?

547


What is the difference between abstract class and interface in php?

518


Why triggers are used in mysql?

528


What is the difference between die () and exit () in php?

505


What does echo mean in php?

552