[eluser]Unknown[/eluser]
This model is returning false from database and when i change the code so as to insert it is inserting data to database.Please help guys .I have no idea what the problem is
class Membership_model extends CI_Model{
function __construct(){
parent::__construct();
}
function validate(){
$this->db->where('user_name',$this->input->post('user_name'));
$this->db->where('password',md5($this->input->post('password')));
$query=$this->db->get('membership');
if($query->num_rows()==1){
return TRUE;
}