0
ユーザーが認証に失敗した後に貴重なものを渡そうとしています。私はウェルカムコントローラに$エラーを渡したいが、どうしたらいいかわからない。助けてください。ありがとうございました。どのようにリダイレクトで貴重なものを渡すのですか?
private function _user_check()
{
//after form validation, I pass username and password to the model
$this->load->model('user_query');
$result=$this->user_query->query($this->input->post('username'),$this->
input->post('password'));
if($result)
{
redirect('main');
}else{
// I am not sure how to pass this error message to my welcome controller
$data['error']='Please check your username or password';
redirect('welcome');
}
}
素晴らしい:このような何かを持つあなたの '歓迎' コントローラで次に
!手伝ってくれてありがとう。 – FlyingCat