Reset to basic

This commit is contained in:
Josh North 2014-08-23 23:16:51 -04:00
parent b3ae041a03
commit e09d5546e6
6 changed files with 0 additions and 111 deletions

View File

@ -1,44 +0,0 @@
<?php
Class Registry {
/*
* @the vars array
* @access private
*/
private $vars = array();
/**
*
* @set undefined vars
*
* @param string $index
*
* @param mixed $value
*
* @return void
*
*/
public function __set($index, $value)
{
$this->vars[$index] = $value;
}
/**
*
* @get variables
*
* @param mixed $index
*
* @return mixed
*
*/
public function __get($index)
{
return $this->vars[$index];
}
}
?>

View File

@ -1,24 +0,0 @@
<?php
class router {
/*
* @the registry
*/
private $registry;
/*
* @the controller path
*/
private $path;
private $args = array();
public $file;
public $controller;
public $action;
function __construct($registry) {
$this->registry = $registry;
}

View File

@ -1,30 +0,0 @@
<?php
/*** include the controller class ***/
include __SITE_PATH . '/application/' . 'controller_base.class.php';
/*** include the registry class ***/
include __SITE_PATH . '/application/' . 'registry.class.php';
/*** include the router class ***/
include __SITE_PATH . '/application/' . 'router.class.php';
/*** include the template class ***/
include __SITE_PATH . '/application/' . 'template.class.php';
/*** auto load model classes ***/
function __autoload($class_name) {
$filename = strtolower($class_name) . '.class.php';
$file = __SITE_PATH . '/model/' . $filename;
if (file_exists($file) == false)
{
return false;
}
include ($file);
}
/*** a new registry object ***/
$registry = new registry;
?>

View File

@ -1,13 +0,0 @@
<?php
/*** error reporting on ***/
error_reporting(E_ALL);
/*** define the site path constant ***/
$site_path = realpath(dirname(__FILE__));
define ('__SITE_PATH', $site_path);
/*** include the init.php file ***/
include 'includes/init.php';
?>