| Server IP : 68.178.202.69 / Your IP : 216.73.216.122 Web Server : Apache System : Linux 69.202.178.68.host.secureserver.net 3.10.0-1160.139.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Nov 3 13:30:41 UTC 2025 x86_64 User : ikioworld ( 1005) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/ikioworld/public_html/application/controllers/contact/ |
Upload File : |
<?php
// defined('BASEPATH') or exit('No direct script access allowed');
// require_once(APPPATH."third_party/phpmailer/class.phpmailer.php");
class Contact extends CI_Controller
{
public function index()
{
$this->load->helper(array('form', 'url', 'common'));
$this->load->library(array('session','pagination','cart'));
$this->load->model('contactmodel', '', true);
$this->load->model('homemodel', '', true);
$this->load->model('Mailmodel', '', true);
$sql=$this->db->query("SELECT * from page where page_name='Contact Us'");
$result = $sql->result();
$title = $result[0]->page_title;
$meta_title = $result[0]->meta_title;
$meta_d =$result[0]->meta_description;
$image = $result[0]->page_image;
$data['title'] = $title ." || IKIO LED LIGHTING";
$data['meta_title'] = $meta_title ." || IKIO LED LIGHTING";
$data['meta_description'] = $meta_d ." || IKIO LED LIGHTING";
$data['image'] = $image;
include APPPATH . "third_party/phpmailer-smtp/class.phpmailer.php";
$mail = new PHPMailer(true);
if(!empty($this->input->post())){
$email = $this->input->post('email');
if($email!=''){
$insert_id = $this->contactmodel->addContact($this->input->post());
$data['fullname'] =$this->input->post('fullname');
$message = "<html>
<head>
<meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
</head>
<body style='background-color:#f6f6f6; box-sizing: border-box; font-family: 'Poppins', sans-serif;'>
<div style='margin:0px auto;background: #f3f3f3;padding: 10px;'>
<div style='border: 1px solid #ccc;background-color:#fff;clear:both;color:#666;line-height:32px;max-width:500px;margin:50px auto;border-radius:5px 5px 5px 5px'>
<div style='color:#fff;text-align:center;padding:0px 0px 10px 0px;background-repeat:no-repeat;background-position:center;background-size:183px;background-color:#000000;width:100%;height:auto;border-radius:5px 5px 0px 0px'>
<img src='".base_url()."/assets/img/logo.png' style=' display: block; margin: 0 auto;width: 140px; padding-top: 15px;'>
</div>
<div style='margin-top:0;margin-right:0;margin-bottom:0;margin-left:0;padding-top:0;padding-right:0;padding-bottom:0px;padding-left:0;font-size:15px'>
<img src='".base_url()."/assets/img/message.png' style=' display: block; margin: 0 auto;width: 100px; padding-top: 15px;'>
<table cellpadding='0' cellspacing='0' style='width: 100%;margin: 8px 1px;font-size: 12px;font-size:12px'>
<tbody>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;'>
<p style='font-weight:bold;text-align: center;font-size: 14px;margin-bottom: 0;color: #fff;text-transform: capitalize; isplay:block; width:100% '></p>
<p style='font-weight:400;text-align: center;font-size: 14px;margin-bottom: 0; display:block; width:100%'><b>Thank You ".$data['fullname']." for writing in to us!</b><br>We at IKIO, value your consideration and interest. If required, someone from our team will get in touch with you within 2 to 3 working days.</p>
<p style='font-weight:400;text-align: center;font-size: 14px;margin-bottom: 0; display:block; width:100%'>In the meantime, please continue exploring our website.</p>
</td>
</tr>
</tbody>
</table>
<p style='padding: 10px 30px;font-weight: bold;text-align: center;font-size: 14px;margin-bottom: 0;background-repeat:no-repeat;background-position:center;background-color:#000000;background: #000000;color: #fff;'> © 2022 IKIO LED LIGHTING. All Rights Reserved.</p>
</div>
</div>
</div>
</div>
</body>
</html>";
$this->Mailmodel->sendMail( "IKIO Contact Form", $email, $data['fullname'], $message );
}
$data['email'] = $this->input->post('email');
$data['fullname'] =$this->input->post('fullname');
$data['content'] = $this->input->post('message');
$data['phone_number'] = $this->input->post('phone_number');
$data['country'] = $this->input->post('country');
$data['state'] = $this->input->post('state');
$data['question'] =$this->input->post('question');
$data['sub'] = $this->input->post('subject');
$sender_mail ='noreply@ikioledlighting.com';
$message = "
<html>
<head>
<meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
</head>
<body style='background-color:#f6f6f6; box-sizing: border-box; font-family: 'Poppins', sans-serif;'>
<div style='margin:0px auto;background: #f3f3f3;padding: 10px;'>
<div style='border: 1px solid #ccc;background-color:#fff;clear:both;color:#666;line-height:32px;max-width:500px;margin:50px auto;border-radius:5px 5px 5px 5px'>
<div style='color:#fff;text-align:center;padding:0px 0px 10px 0px;background-repeat:no-repeat;background-position:center;background-size:183px;background-color:#000000;width:100%;height:auto;border-radius:5px 5px 0px 0px'>
<img src='".base_url()."/assets/img/logo.png' style=' display: block; margin: 0 auto;width: 140px; padding-top: 15px;'>
<p style='font-weight:bold;text-align: center;font-size: 14px;margin-bottom: 0;color: #fff;text-transform: capitalize; display:block; width:100% '>A New Contact Enquiry is there !</b></p>
</div>
<div style='margin-top:0;margin-right:0;margin-bottom:0;margin-left:0;padding-top:0;padding-right:0;padding-bottom:0px;padding-left:0;font-size:15px'>
<img src='".base_url()."/assets/img/message.png' style=' display: block; margin: 0 auto;width: 100px; padding-top: 15px;'>
<table cellpadding='0' cellspacing='0' style='width: 100%;margin: 8px 1px;font-size: 12px;font-size:12px'>
<tbody>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Full Name</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left; '> ".$data['fullname']." </td>
</tr>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Email</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['email']."</td>
</tr>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Phone</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['phone_number']."</td>
</tr>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Country</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['country']."</td>
</tr>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>State</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['state']."</td>
</tr>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Question</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['question']."</td>
</tr>
<tr>
<td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Message</td>
<td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['content']."</td>
</tr>
</tbody>
</table>
<p style='padding: 10px 30px;font-weight: bold;text-align: center;font-size: 14px;margin-bottom: 0;background-repeat:no-repeat;background-position:center;background-color:#000000;background: #000000;color: #fff;'> © 2022 IKIO LED LIGHTING. All Rights Reserved.</p>
</div>
</div>
</div>
</div>
</body>
</html>";
$this->Mailmodel->sendMail( "IKIO Contact Form", "info@ikioledlighting.com", "Ikio Led Lighting", $message );
$this->session->set_flashdata('message',"<h1 class='career_message'>Thank You for submitting your request. We will contact you within 24 working hours.</h1><span class='crossbars_wrong'></span>");
}
$data['category'] = $this->homemodel->getCategory();
$data['subcategorys'] =$this->homemodel->getSubCategory();
$this->load->view('inc/header',$data);
$this->load->view('contact/index', $data);
$this->load->view('inc/footer',$data);
}
public function HomeEnquiry(){
$this->load->helper(array('form', 'url', 'common'));
$this->load->library(array('session','pagination','cart'));
$this->load->model('contactmodel', '', true);
$this->load->model('homemodel', '', true);
$this->load->model('Mailmodel', '', true);
include APPPATH . "third_party/phpmailer-smtp/class.phpmailer.php";
$mail = new PHPMailer(true);
// if(!empty($this->input->post())){
// $email = $this->input->post('email');
// if($email!=''){
// $insert_id = $this->contactmodel->addContact($this->input->post());
// $data['fullname'] =$this->input->post('fullname');
// $message = "<html>
// <head>
// <meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
// </head>
// <body style='background-color:#f6f6f6; box-sizing: border-box; font-family: 'Poppins', sans-serif;'>
// <div style='margin:0px auto;background: #f3f3f3;padding: 10px;'>
// <div style='border: 1px solid #ccc;background-color:#fff;clear:both;color:#666;line-height:32px;max-width:500px;margin:50px auto;border-radius:5px 5px 5px 5px'>
// <div style='color:#fff;text-align:center;padding:0px 0px 10px 0px;background-repeat:no-repeat;background-position:center;background-size:183px;background-color:#000000;width:100%;height:auto;border-radius:5px 5px 0px 0px'>
// <img src='".base_url()."/assets/img/logo.png' style=' display: block; margin: 0 auto;width: 140px; padding-top: 15px;'>
// </div>
// <div style='margin-top:0;margin-right:0;margin-bottom:0;margin-left:0;padding-top:0;padding-right:0;padding-bottom:0px;padding-left:0;font-size:15px'>
// <img src='".base_url()."/assets/img/message.png' style=' display: block; margin: 0 auto;width: 100px; padding-top: 15px;'>
// <table cellpadding='0' cellspacing='0' style='width: 100%;margin: 8px 1px;font-size: 12px;font-size:12px'>
// <tbody>
// <tr>
// <td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;'>
// <p style='font-weight:bold;text-align: center;font-size: 14px;margin-bottom: 0;color: #fff;text-transform: capitalize; isplay:block; width:100% '></p>
// <p style='font-weight:400;text-align: center;font-size: 14px;margin-bottom: 0; display:block; width:100%'><b>Thank You ".$data['fullname']." for writing in to us!</b><br>We at IKIO, value your consideration and interest. If required, someone from our team will get in touch with you within 2 to 3 working days.</p>
// <p style='font-weight:400;text-align: center;font-size: 14px;margin-bottom: 0; display:block; width:100%'>In the meantime, please continue exploring our website.</p>
// </td>
// </tr>
// </tbody>
// </table>
// <p style='padding: 10px 30px;font-weight: bold;text-align: center;font-size: 14px;margin-bottom: 0;background-repeat:no-repeat;background-position:center;background-color:#000000;background: #000000;color: #fff;'> © 2022 IKIO LED LIGHTING. All Rights Reserved.</p>
// </div>
// </div>
// </div>
// </div>
// </body>
// </html>";
// $this->Mailmodel->sendMail( "IKIO Home Enquiry", $email, $data['fullname'], $message );
// }
// $data['email'] = $this->input->post('email');
// $data['fullname'] =$this->input->post('fullname');
// $data['content'] = $this->input->post('message');
// $data['phone_number'] = $this->input->post('phone_number');
// $data['country'] = $this->input->post('country');
// $sender_mail ='noreply@ikioledlighting.com';
// $message = "
// <html>
// <head>
// <meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
// </head>
// <body style='background-color:#f6f6f6; box-sizing: border-box; font-family: 'Poppins', sans-serif;'>
// <div style='margin:0px auto;background: #f3f3f3;padding: 10px;'>
// <div style='border: 1px solid #ccc;background-color:#fff;clear:both;color:#666;line-height:32px;max-width:500px;margin:50px auto;border-radius:5px 5px 5px 5px'>
// <div style='color:#fff;text-align:center;padding:0px 0px 10px 0px;background-repeat:no-repeat;background-position:center;background-size:183px;background-color:#000000;width:100%;height:auto;border-radius:5px 5px 0px 0px'>
// <img src='".base_url()."/assets/img/logo.png' style=' display: block; margin: 0 auto;width: 140px; padding-top: 15px;'>
// <p style='font-weight:bold;text-align: center;font-size: 14px;margin-bottom: 0;color: #fff;text-transform: capitalize; display:block; width:100% '>A New Contact Enquiry is there !</b></p>
// </div>
// <div style='margin-top:0;margin-right:0;margin-bottom:0;margin-left:0;padding-top:0;padding-right:0;padding-bottom:0px;padding-left:0;font-size:15px'>
// <img src='".base_url()."/assets/img/message.png' style=' display: block; margin: 0 auto;width: 100px; padding-top: 15px;'>
// <table cellpadding='0' cellspacing='0' style='width: 100%;margin: 8px 1px;font-size: 12px;font-size:12px'>
// <tbody>
// <tr>
// <td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Full Name</td>
// <td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left; '> ".$data['fullname']." </td>
// </tr>
// <tr>
// <td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Email</td>
// <td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['email']."</td>
// </tr>
// <tr>
// <td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Phone</td>
// <td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['phone_number']."</td>
// </tr>
// <tr>
// <td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Country</td>
// <td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['country']."</td>
// </tr>
// <tr>
// <td style='border-bottom:1px solid #eeee;text-align:left;padding: 10px;color: #000;width: 171px;font-weight:bold;font-size: 15px;background: url(".base_url()."assets/img/dots.png);background-size: 3px;background-repeat: no-repeat;background-position: right;'>Message</td>
// <td style='border-bottom:1px solid #eeee;font-size: 17px;padding: 10px;color: #000;text-align: left;'>".$data['content']."</td>
// </tr>
// </tbody>
// </table>
// <p style='padding: 10px 30px;font-weight: bold;text-align: center;font-size: 14px;margin-bottom: 0;background-repeat:no-repeat;background-position:center;background-color:#000000;background: #000000;color: #fff;'> © 2022 IKIO LED LIGHTING. All Rights Reserved.</p>
// </div>
// </div>
// </div>
// </div>
// </body>
// </html>";
// $this->Mailmodel->sendMail( "IKIO Home Form", "info@ikioledlighting.com", "Ikio Led Lighting", $message );
// $this->session->set_flashdata('message',"<h1 class='career_message'>Thank You for submitting your request. We will contact you within 24 working hours.</h1><span class='crossbars_wrong'></span>");
// }
redirect('/home/index', 'refresh');
}
}