You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
539 B
35 lines
539 B
9 years ago
|
<?php
|
||
|
/**
|
||
|
* Login Class
|
||
|
*/
|
||
9 years ago
|
class Login extends CI_Controller
|
||
9 years ago
|
{
|
||
|
|
||
|
public function __construct()
|
||
|
{
|
||
|
parent::__construct();
|
||
|
}
|
||
|
|
||
|
public function index()
|
||
|
{
|
||
|
// Header
|
||
|
$this->load->view('header');
|
||
|
|
||
9 years ago
|
$this->form_validation->set_rules('username', 'Username', 'required');
|
||
|
$this->form_validation->set_rules('password', 'Password', 'required');
|
||
|
|
||
|
if ($this->form_validation->run() == FALSE)
|
||
|
{
|
||
|
// login page
|
||
|
$this->load->view('login');
|
||
|
} else {
|
||
|
echo "Done";
|
||
|
}
|
||
|
|
||
9 years ago
|
|
||
|
// Footer
|
||
|
$this->load->view('footer');
|
||
|
}
|
||
|
}
|
||
|
|
||
|
?>
|