<commit_before><?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Admin extends CI_Controller {
	
	public function index(){
		if (!isset($_SESSION['logged_in'])){
			redirect('register');
		}

		$data=$this->pageData();
		$this->load->view('templates/header_admin', $data);
		$this->load->view('admin_home', $data);
		$this->load->view('templates/footer');
	}

	public function pageData(){
		//Load tables library
		$this->load->library('table');

		// Query the database and get results
		$data['windows'] = $this->db->get('windows');
		
		// Create custom headers
		$header = array('Semester', 'Begin Accepting Applications', 'End Accepting Applications', 'Open Comment Period', 'Close Comment Period');<commit_msg> add sesseion<commit_after><?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Admin extends CI_Controller {
	public function __construct(){
		parent::__construct();
		if (!isset($_SESSION['logged_in'])||$this->session->userdata('profession')!='admin'){
			redirect('register');
		}
	}
	public function index(){
		if (!isset($_SESSION['logged_in'])){
			redirect('register');
		}

		$data=$this->pageData();
		$this->load->view('templates/header_admin', $data);
		$this->load->view('admin_home', $data);
		$this->load->view('templates/footer');
	}

	public function pageData(){
		//Load tables library
		$this->load->library('table');

		// Query the database and get results
		$data['windows'] = $this->db->get('windows');
		
		// Create custom headers
		$header = array('Semester', 'Begin Accepting Applications', 'End Accepting Applications', 'Open Comment Period', 'Close Comment Period');
{'fraction_non_alphanumeric': 0.1860325105358218, 'fraction_numerical': 0.0, 'mean_word_length': 5.319391634980988, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6417469', 'n_tokens_mistral': 533, 'n_tokens_neox': 481, 'n_words': 120}