| Name: | $name |
| Email: | |
| Number: | $number |
| Comment: | $comment |
Sent via LeafLine Contact Form
"; include('smtp/PHPMailerAutoload.php'); $mail=new PHPMailer(true); // smtp Settings $mail->isSMTP(); // Set mailer to use SMTP $mail->Host="smtp.gmail.com"; // SMTP servers $mail->Port=587; //specify SMTP Port $mail->SMTPSecure="tls"; // Enable TLS encryption, `ssl` also accepted $mail->SMTPAuth=true; // Enable SMTP authentication $mail->Username="your_email@gmail.com"; // (SMTP Username) Your Mail $mail->Password="Your App Password"; // (SMTP Password) Your app password $mail->setFrom($email, $name); $mail->addAddress("your_email@gmail.com", "LeafLine"); // (Your Mail) An email address that will receive the email with the output of the form $mail->IsHTML(true); // Set email format to HTML $mail->Subject = "(LeafLine) New Contact Info"; $mail->Body = $html; $mail->SMTPOptions=array('ssl'=>array( 'verify_peer'=>false, 'verify_peer_name'=>false, 'allow_self_signed'=>false )); $msg=""; if($mail->send()){ //echo "Mail send"; $msg="Sent Successfully"; }else{ //echo "Error occur"; $msg="Error Occur"; } echo $msg; } ?>