true または false だけを返す if else ステートメントはほとんどなく、すべてのステートメントが正しく機能していません。私は多くの方法を試しましたが、問題がわかりません.誰かがこれを修正すると非常に役に立ちます.
ここにモデルの私のコードがあります
function exists($email){
$this->db->where('email',$email);
$query=$this->db->get('member_info');
echo "model is called"; // after execution this text is shown but not the others
if ($query->num_rows == 1) {
return true;
echo "i got one";
}else{
return false;
echo "i got nothing";
}
}
ここに私のコントローラーがあります
function is_exists($email){
echo "this is loaded"; //this line works properly
if($this->validation_model->exists($email)){
return false;
echo "true"; //this doesn't
}else{
return true;
echo "false"; // this doesn't
}
}