AddReplyTo($email, $nume);
$admin_email = get_option('admin_email');
//dv($admin_email);die();
$new_mail->AddAddress($admin_email);
//$new_mail->AddAddress('gabriel.ilie@gmail.com', 'Gabriel Ilie');
$new_mail->SetFrom('contact@iqon.com', 'CONTACT FORM');
$new_mail->Subject = '[IQON CONTACT FORM] '.$nume.' has sent you a message. Subject: '.$subject;
$new_mail->AltBody = 'To view the message, please use an HTML compatible email viewer!'; // optional - MsgHTML will create an alternate automatically
//$new_mail->MsgHTML(file_get_contents('contents.html'));
$html = $nume.' has sent you an message.
E-mail: '.$email.'
Subject: '.$subject.'
Message: '.$message;
$new_mail->MsgHTML($html);
$new_mail->Send();
} catch (phpmailerException $e) {
echo $e->errorMessage(); //Pretty error messages from PHPMailer
} catch (Exception $e) {
echo $e->getMessage(); //Boring error messages from anything else!
}
echo '';
die();
}
}
?>