From 7d7c11adc78e2f5393523a2223f2035253220afc Mon Sep 17 00:00:00 2001 From: Starla Insigna Date: Tue, 2 Nov 2010 22:06:37 -0400 Subject: Created new maintenance page Requires modification of Fourm's includes/functions.php --- includes/maintenance.php | 30 ++++++++++++------- theme/maintenance.tpl | 77 ++++++++++++++++++++++++++++++++++++++++++++---- 2 files changed, 91 insertions(+), 16 deletions(-) diff --git a/includes/maintenance.php b/includes/maintenance.php index b3150c5..c3041cf 100755 --- a/includes/maintenance.php +++ b/includes/maintenance.php @@ -22,18 +22,28 @@ if (!defined('S_INCLUDE_FILE')) {define('S_INCLUDE_FILE',1);} require('headerproc.php'); -$getconfig = "SELECT * FROM config WHERE name = \"maintenanceMode\""; -$getconfig2 = mysql_query($getconfig); -$getconfig3 = mysql_fetch_array($getconfig2); -if ($getconfig3['value'] == '1') +function isInMaintenance() { - if (($_SERVER['REMOTE_ADDR'] != '127.0.0.1') && (!isAdmin())) - { - $template = new FITemplate('maintenance'); - $template->display($template); + $getconfig = "SELECT * FROM config WHERE name = \"maintenanceMode\""; + $getconfig2 = mysql_query($getconfig); + $getconfig3 = mysql_fetch_array($getconfig2); + if ($getconfig3['value'] == '1') + { + if (($_SERVER['REMOTE_ADDR'] != '127.0.0.1') && (!isAdmin())) + { + return true; + } + } + + return false; +} + +if (isInMaintenance()) +{ + $template = new FITemplate('maintenance'); + $template->display($template); - exit; - } + exit; } ?> diff --git a/theme/maintenance.tpl b/theme/maintenance.tpl index 349c6d1..d07b2a5 100755 --- a/theme/maintenance.tpl +++ b/theme/maintenance.tpl @@ -1,6 +1,71 @@ -

Four Island is under maintenance

- -

I'm sorry, but you've caught Four Island off guard. We're currently upgrading the website to accomidate for some fun new features we've thrown in, -so Four Island'll be down for a few minutes. Please try again soon and thanks for your interest in Four Island!

- -

--Starla Insigna

+ + + + Four Island + + + + + +
+ + +

Four Island is currently under maintenance

+ +

We'll be back before you know it. Just sit tight for a while.

+
+ + -- cgit 1.4.1