Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include "classes/class.phpmailer.php";
- $mail = new PHPMailer;
- $mail->IsSMTP();
- $mail->SMTPSecure = 'ssl';
- $mail->Host = "domain.com"; //host masing2 provider email
- $mail->SMTPDebug = 2;
- $mail->Port = 465;
- $mail->SMTPAuth = true;
- $mail->Username = "xxxx@domain.com"; //user email
- $mail->Password = "knkidqphlkgdgokq"; //password email
- $mail->SetFrom("xxxx@domain.com","Nama pengirim"); //set email pengirim
- $mail->Subject = "Testing"; //subyek email
- $mail->AddAddress("aaaa@domain.net","nama email tujuan"); //tujuan email
- $mail->MsgHTML("Testing...");
- if($mail->Send()) echo "Message has been sent";
- else echo "Failed to sending message";
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement