can't send email using YiiMailer

i can’t sending email using YiiMailer. nothing error but the email not send. please help me.


‘mail’ => array(

            'class' => 'ext.yii-mail.YiiMail',








            'viewPath' => 'application.views.mail',




Class EmailController extends Controller {


public function actionKirim() {

$this -> layout = ‘null’;

if (isset($_POST[‘Data’])) {

//amdil data dari form

$data = $_POST[‘Data’];

//set email to

$emailTo = $data[‘email’];

//set subject

$subject = ‘Anda Mendapatkan Disposisi Surat’;

//set message

$message = ‘Anda mendapatkan disposisi surat. Silahkan cek E-OFFICE Anda’;

//panggil php mailer

$mail = Yii::app() -> Smtpmail;

//add replay to (penerima membalas akan ditujukan ke email ini)

$mail -> AddReplyTo(‘’, ‘’);

//add bcc

$mail -> AddBcc(‘’);

//menyatakan email dikirim dari siapa

$mail -> SetFrom(‘’, ‘Notifikasi E-OFFICE’);

//set subject

$mail -> Subject = $subject;

//set message untuk dikirim

$mail -> MsgHTML($message);

//set email address to dikirim

$mail -> AddAddress($emailTo, "");

//jika email tidak dikirim maka tampilkan error

if (!$mail -> Send()) {

echo "Mailer Error: " . $mail -> ErrorInfo;

} else {

//else tampilkan sukses

echo "Message sent!";



//render form untuk kirim email

$this -> render(‘index2’);



//located at protected\controllers




  &lt;td class=&quot;a&quot;&gt;Email Penerima&lt;/td&gt;

  &lt;td class=&quot;a1&quot;&gt;:&lt;/td&gt;

  &lt;td class=&quot;b&quot;&gt;&lt;input size =&quot;64&quot; name = &quot;data[email]&quot;/&gt;&lt;/td&gt;



<div class=“button”><a class=“button” onclick=“fp(\‘content\’,\‘f3\’,\’’.Yii::app()->createUrl(‘smdata/index2’).’\’,\‘tmb4=Simpan\’);”>Simpan</a></div>