Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 88
Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 215
Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 216
Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 217
Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 218
Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 219
Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 220
session->userdata('user_type') =='student') {
$this->session->set_flashdata('flash_data', 'You don\'t have access!');
redirect('Learning');
}elseif($this->session->userdata('user_type') =='employee'){
$this->session->set_flashdata('flash_data', 'You don\'t have access!');
redirect('Admin');
}
}
/**
* Index Page for this controller.
*
* Maps to the following URL
* http://example.com/index.php/welcome
* - or -
* http://example.com/index.php/welcome/index
* - or -
* Since this controller is set as the default controller in
* config/routes.php, it's displayed at http://example.com/
*
* So any other public methods not prefixed with an underscore will
* map to /index.php/welcome/
* @see https://codeigniter.com/user_guide/general/urls.html
*/
public function index()
{
$this->load->view('includes/welcome_header');
$this->load->view('welcome/welcome');
$this->load->view('includes/students_footer');
}
public function welcome2()
{
//$this->load->view('includes/students_header');
$this->load->view('welcome/welcome2');
//$this->load->view('includes/students_footer');
}
public function login()
{
$this->load->view('pages/login');
}
public function about()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/about');
$this->load->view('includes/students_footer');
}
public function contacts()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/contacts');
$this->load->view('includes/students_footer');
}
public function business_information()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/business_information');
$this->load->view('includes/students_footer');
}
public function markets()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/market_products');
$this->load->view('includes/students_footer');
}
public function product_markets()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/markets');
$this->load->view('includes/students_footer');
}
public function market_view()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/market_view');
$this->load->view('includes/students_footer');
}
public function product_details()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/product_details');
$this->load->view('includes/students_footer');
}
public function products()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/products');
$this->load->view('includes/students_footer');
}
public function links()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/links');
$this->load->view('includes/students_footer');
}
public function law()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/law');
$this->load->view('includes/students_footer');
}
public function policies()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/policies');
$this->load->view('includes/students_footer');
}
public function read_business_information()
{
$this->load->view('includes/students_header');
$this->load->view('welcome/read_business_information');
$this->load->view('includes/students_footer');
}
public function download_app(){
$this->load->view('pages/download_app');
}
public function privacy()
{
$this->load->view('pages/privacy');
}
public function forget_password()
{
$this->load->view('pages/forget_password');
}
public function register()
{
$this->load->view('includes/printing_header');
$this->load->view('pages/register');
$this->load->view('includes/printing_footer');
}
public function language(){
//change language session...
$this->session->set_userdata('language', $_REQUEST['id']);
redirect($_SERVER['HTTP_REFERER']);
}
public function register_student()
{
if($_POST){
$full_name = $this->input->post('first_name').' '.$this->input->post('last_name');
$mobile=$this->input->post('mobile');
$mobile =str_replace("-","",$mobile);
$mobile =str_replace("(","",$mobile);
$mobile =str_replace(")","",$mobile);
$mobile =str_replace(" ","",$mobile);
$mobile=substr($mobile, -9);
$mobile='255'.$mobile;
$data_ary = array(
'full_name'=>$this->input->post('first_name').' '.$this->input->post('last_name'),
'email'=>$this->input->post('email'),
'mobile'=>$mobile,
'gender'=>$this->input->post('gender'),
'location'=>$this->input->post('location'),
'password'=>md5($this->input->post('password')),
'password1'=>$this->input->post('password'),
'date_registered'=>date('Y-m-d H:i:s'),
'registered_through'=>'web',
);
$data_ary = $this->security->xss_clean($data_ary);
$this->db->where('mobile',$mobile);
$count=$this->db->count_all_results('students');
$this->db->where('email',$this->input->post('email'));
$count1=$this->db->count_all_results('students');
if($count>0){
redirect('Welcome/register?Error');
}elseif($count1>0){
redirect('Welcome/register?Error1');
}else{
$this->db->insert('students',$data_ary);
$student_id=$this->db->insert_id();
$data1=array(
'student_id'=>$student_id,
'business_name'=>$this->input->post('business_name'),
'descriptions'=>$this->input->post('descriptions'),
);
$this->db->insert('business_profiles',$data1);
$lang=$this->input->post('lang');
$data_session = array(
'full_name'=>$this->input->post('first_name').' '.$this->input->post('last_name'),
'id'=>$student_id,
'email'=>$this->input->post('email'),
'mobile'=>$mobile,
'gender'=>$this->input->post('gender'),
'location'=>$this->input->post('location'),
'password'=>md5($this->input->post('password')),
'password1'=>$this->input->post('password'),
'date_registered'=>date('Y-m-d H:i:s'),
'registered_through'=>'web',
'user_type'=>'student',
'language' => $lang,
);
//function to send email
$name=$full_name;
$to = $this->security->xss_clean($this->input->post('email'));
$subject = "TWCC Digital Platform login account details";
$username=$mobile;
$email=$this->security->xss_clean($this->input->post('email'));
$url= 'https://womenchamber.or.tz/Welcome/verify_email?verified='.base64_encode($student_id);
$message = "Use your phone number (".$username.") or email address(".$email. ") and password ".$this->input->post('password')." to login
Tanzania Women chamber of Commerce (TWCC)
";
// Always set content-type when sending HTML email
$headers = "MIME-Version: 1.0" . "\r\n";
$headers .= "Content-type:text/html;charset=UTF-8" . "\r\n";
// More headers
$headers .= 'From: ' . "\r\n";
mail($to,$subject,$message,$headers);
//end of email verification
$this->session->set_userdata($data_session);
redirect('Learning');
}
}else{
redirect($_SERVER['HTTP_REFERER']);
}
}
public function verify_email(){
$this->load->view('includes/printing_header');
$this->load->view('pages/verify_email');
$this->load->view('includes/printing_footer');
}
public function change_password(){
$this->load->view('pages/change_password');
}
}