<?php
class MY_Controller extends CI_Controller
{
function __construct(){
	parent::__construct();

	if(!$this->session->userdata('usuario_logueado')){
		redirect('main/login');
	}
	
	if ($this->config->item('language')!= $this->session->userdata('usuario_lenguaje')) {
		$this->config->set_item('language',$this->session->userdata('usuario_lenguaje'));
		$this->config->set_item('language_code',$this->session->userdata('usuario_idioma'));
		
	}
	$this->lang->load('eap', $this->config->item('language'));
	$this->lang->load('sec', $this->config->item('language'));
}

}