(03-25-2016, 09:45 AM)Rhyno_xD Wrote: did you extend CI_Model class also post the code here.
class model_users extends CI_Model{
public function __construct()
parent::__construct();
$this->load->database();
public function can_log_in(){
$this->db->where('email',$this->input->post('email'));
$this->db->where('password',md5($this->input->post('password')));
$query = $this->db->get('user');
if ($query->num_rows()== 1){
return true;
}else{
return false;
}
}
}