嗨,大家好,我只是为了显示错误消息而只是简单地显示了代码,但现在仍在显示。 - 你可以在开始做这个在codeigniter中显示带有错误消息的值页面
首先发起的空属性,所以你知道它的存在:
public function check_profile_ifexist($id)
{
if($this->input->post('edit')){
$this->form_validation->set_rules('email','Email','trim|valid_email|is_unique[user_details.email]');
$this->form_validation->set_rules('username','Username','trim|min_length[6]|max_length[20]|is_unique[user_details.username]|xss_clean'); $this->form_validation->set_message('is_unique',"That %s already exists!");
$this->form_validation->set_message('max_length', 'the maximum characters for %s is 20');
$this->form_validation->set_message('min_length', 'the minimum characters for %s is 6');
if ($this->form_validation->run())
{
$this->load->model('model_user_manage');
$em=$this->model_user_manage->update_all($id);
}
else
{
$this->view_profile($id);
}
}
}
你好谢赫你能帮助我吗? – webstudent