class home extends CI_Controller {
public function __construct() {
parent::__construct();
$this->load->library('form_validation');
$this->load->helper('form');
}
public function login() {
$this->load->model('auth_model');
if ($this->input->post('submit')) {
$config = array(
array(
"field" => "username",
"label" => "Username",
"rules" => "required"
),
array(
"field" => "password",
"label" => "Password",
"rules" => "required"
)
);
$this->form_validation->set_rules($config);
$this->form_validation->set_error_delimiters('<li>', '</li>');