From 5b6fa42915054cd70c9b52171dc4fc1801dd7f01 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Sun, 2 Oct 2011 09:57:07 +0000 Subject: new php has namespace as a reserved word. yay --- web/include/Namespace.inc | 4 ++-- web/index.php | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/web/include/Namespace.inc b/web/include/Namespace.inc index 51542f1..56295ff 100644 --- a/web/include/Namespace.inc +++ b/web/include/Namespace.inc @@ -10,7 +10,7 @@ require_once("../include/Messages.inc"); require_once("../include/Session.inc"); require_once("../include/User.inc"); -class Namespace { +class Name_space { var $have_database = false; var $have_session = false; var $have_user = false; @@ -21,7 +21,7 @@ class Namespace { var $session = false; var $user = false; - function Namespace($options = array()) { + function Name_space($options = array()) { if ($options['have_database']) $this->have_database = $options['have_database']; if ($options['have_session']) diff --git a/web/index.php b/web/index.php index 7852e25..aabfcbd 100644 --- a/web/index.php +++ b/web/index.php @@ -4,7 +4,7 @@ require_once( "../include/Namespace.inc" ); require_once( "../include/Template.inc" ); require_once("../include/Tools.inc"); -$namespace = new Namespace( +$name_space = new Name_space( array( have_database => 0, have_session => 0, have_user => 0 @@ -15,13 +15,13 @@ $namespace = new Namespace( $data = array(); $data['remotehostname'] = gethostbyaddr($_SERVER['REMOTE_ADDR']); $data['remoteip'] = $_SERVER['REMOTE_ADDR']; -$data['user'] = $namespace->session->data['user']['username']; +$data['user'] = $name_space->session->data['user']['username']; $data['have_ssl'] = $_SERVER['SSL_PROTOCOL'] ? 1 : 0; -$template = new Template('index.html', $namespace->config->template_path); +$template = new Template('index.html', $name_space->config->template_path); $template->parse($data); print $template->output(); -$namespace->stop(); +$name_space->stop(); # vim:ts=4: # vim:shiftwidth=4: -- cgit v1.2.3