|
function index()
{
$this->load->helper(array('form', 'url'));
$this->load->library('form_validation');
$this->form_validation->set_rules('username', 'Username', 'required');
$this->form_validation->set_rules('password', 'Password', 'required');
$this->form_validation->set_rules('passconf', 'Password Confirmation', 'required');
$this->form_validation->set_rules('email', 'Email', 'required');
if ($this->form_validation->run() == FALSE)
{
$this->load->view('file');
}
else
{
$this->load->view('formsuccess');
}
}这里的$this->form_validation->set_rules是什么意思啊?不懂,还有后面跟的属性都是什么意思?请高手给详细解释下,谢谢!!
|
|