Show DevBest [Php] How to create an email script! [Php]

Status
Not open for further replies.

DaLightz

See ya'll in the afterlife.
May 19, 2012
1,136
262
Hello all. Just a small tutorial on how to create a simple PHP email script.

Here we go.,
PHP:
<?php //Start off our script.
 
$Reciever = "[email protected]"; //Who does this email go to?
 
  $Subject = "Hello!"; //What is the topic?
 
      $Body = "Hello! How are you?"; // Whats the message?
// Now we will see if it gets sent!
if(mail($Reciever, $Subject, $Body)){
echo 'Message was successfully sent!';
}else{
echo 'Message has failed to send!';
?>
This is quite usefull if you are trying to create a blog plugin for someone, etc.
Hope you all enjoyed. Like!
 

LoW

Learner.
Jun 16, 2011
600
105
Hello all. Just a small tutorial on how to create a simple PHP email script.

Here we go.,
PHP:
<?php //Start off our script.
 
$Reciever = "[email protected]"; //Who does this email go to?
 
  $Subject = "Hello!"; //What is the topic?
 
      $Body = "Hello! How are you?"; // Whats the message?
// Now we will see if it gets sent!
if(mail($Reciever, $Subject, $Body)){
echo 'Message was successfully sent!';
}else{
echo 'Message has failed to send!';
?>
This is quite usefull if you are trying to create a blog plugin for someone, etc.
Hope you all enjoyed. Like!
Thank you for this :)
 
Status
Not open for further replies.

Users who are viewing this thread

Top