Advertisement
emrancu1

PHP mail Sending script

Jul 20th, 2015
247
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.51 KB | None | 0 0
  1.  
  2. if (isset($_POST["submit"])) {
  3.         $name = $_POST['name'];
  4.         $email = $_POST['email'];
  5.         $message = $_POST['message'];
  6.         $from = "Mark Theme Client's Mail";
  7.        $to="emran@gmail.com,";
  8.        $to.="rakib@gmail.com";
  9.        $subject = 'Message from Mark Theme ';
  10.        $body = 'From: '.$name .'<br> E-Mail: '.$email .'<br> Message:<br> ' .$message;
  11.       $status= mail($to, $subject, $body, $from);
  12. if(!$status){
  13.    
  14.     echo'Failed to send';
  15. }
  16. else{
  17.     echo'Thank You !';
  18.     echo $body;
  19. }
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement