53 lines
1.5 KiB
PHP
53 lines
1.5 KiB
PHP
<?php
|
|
|
|
defined('BASEPATH') OR exit('No direct script access allowed');
|
|
|
|
class Auth extends CI_Controller {
|
|
|
|
public function index() {
|
|
//$this->load->view('home/home');
|
|
// echo "START LOGIN";
|
|
$data = array();
|
|
|
|
if ($_POST){
|
|
$this->renderMemberPages('view_dash', $data);
|
|
}
|
|
$this->renderAuthPages('view_login', $data);
|
|
|
|
//$this->load->view('auth/view_head');
|
|
//$this->load->view('auth/view_login');
|
|
//$this->load->view('auth/view_foot');
|
|
}
|
|
|
|
public function newuser() {
|
|
//$this->load->view('home/home');
|
|
$this->load->view('auth/view_head');
|
|
$this->load->view('auth/view_register');
|
|
$this->load->view('auth/view_foot');
|
|
}
|
|
|
|
public function resetpass() {
|
|
//$this->load->view('home/home');
|
|
//echo "START RESET 1";
|
|
$this->load->view('auth/view_head');
|
|
$this->load->view('auth/view_reset_password');
|
|
$this->load->view('auth/view_foot');
|
|
}
|
|
|
|
private function renderAuthPages($pagename, $data) {
|
|
|
|
$this->load->view('auth/view_head');
|
|
$this->load->view('auth/' . $pagename, $data);
|
|
$this->load->view('auth/view_foot');
|
|
return 0;
|
|
}
|
|
|
|
private function renderMemberPages($pagename, $data) {
|
|
// $this->load->view('member/view_securehead');
|
|
$this->load->view('member/' . $pagename, $data);
|
|
// $this->load->view('member/view_securefoot');
|
|
return 0;
|
|
}
|
|
|
|
}
|