public function EmailTest()
{
/* email */
date_default_timezone_set("Asia/Calcutta"); //India time (GMT+5:30)
$datetime = date('d-m-Y H:i:s');
$from_email = "in.mukeshsaini@gmail.com";
$to_email = "in.digitaldunia@gmail.com";
$subject = " Enquiry";
$message = "<h1> Dynamic Website Enquiry </h1>";
$message .= "<b>Time : ".$datetime ."</b><br/>";
$message .= "<b>Mobile: 9024051135</b><br/>";
$header = "From: '.$from_email.' \r\n";
$header1 = "MIME-Version: 1.0\r\n";
$header2 = "Content-type: text/html\r\n";
//Load email library
$this->load->library('email');
$this->email->from($from_email,' Test message');
$this->email->to($to_email);
// $this->email->cc('webbunique@gmail.com');
$this->email->cc('in.mukeshsaini@gmail.com');
$this->email->subject($subject);
$this->email->message($message);
$this->email->set_header('MIME-Version', '1.0; charset=utf-8');
$this->email->set_header('Content-type', 'text/html');
//Send mail
if($this->email->send()){
echo $this->session->set_flashdata("email_sent","Congragulation Email Send Successfully.");
}
else{
echo $this->session->set_flashdata("email_sent","You have encountered an error");
}
/* email */
echo 'send............';
}
/*Login email */