[phpMP-CVS] CVS: phpMP index.php,1.13,1.14 modules.php,1.1,1.2
Status: Pre-Alpha
Brought to you by:
heimidal
From: Brian R. <hei...@us...> - 2002-04-10 21:22:06
|
Update of /cvsroot/phpmp/phpMP In directory usw-pr-cvs1:/tmp/cvs-serv19300 Modified Files: index.php modules.php Log Message: Updated dev info. Added module error support. Index: index.php =================================================================== RCS file: /cvsroot/phpmp/phpMP/index.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -r1.13 -r1.14 *** index.php 9 Apr 2002 22:10:40 -0000 1.13 --- index.php 10 Apr 2002 21:22:02 -0000 1.14 *************** *** 12,16 **** Lead Programmer: Brian Rose ! Lead Designer: Evan Weatherhead Filename: /index.php --- 12,16 ---- Lead Programmer: Brian Rose ! Lead Designer: Trevor Joynson Filename: /index.php Index: modules.php =================================================================== RCS file: /cvsroot/phpmp/phpMP/modules.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** modules.php 10 Apr 2002 04:38:35 -0000 1.1 --- modules.php 10 Apr 2002 21:22:02 -0000 1.2 *************** *** 12,16 **** Lead Programmer: Brian Rose ! Lead Designer: Evan Weatherhead Filename: /modules.php --- 12,16 ---- Lead Programmer: Brian Rose ! Lead Designer: Trevor Joynsond Filename: /modules.php *************** *** 31,35 **** ******************************************************************************/ - // Include The Main Configuration File include("config.php"); --- 31,34 ---- *************** *** 38,47 **** } - // Include The Main Core File include($MPCONF['GEN']['abs_path'] . "/includes/core.php"); global $PHPMP; - // Start phpMP $PHPMP = new PHPMP(); --- 37,44 ---- *************** *** 58,67 **** $this->modulename = $HTTP_GET_VARS['module']; ! $query = $DBA->query("SELECT * FROM " . $MPCONF['DB']['table_prefix'] . "modules WHERE unixname='" . $this->modulename . "' LIMIT 1"); ! if(@mysql_num_rows($query)) { $MPCONF['MOD'] = @mysql_fetch_array($query); ! } else { ! die("Module requested but not found."); ! } } } --- 55,68 ---- $this->modulename = $HTTP_GET_VARS['module']; ! $query = $DBA->query("SELECT * FROM " . $MPCONF['DB']['table_prefix'] . "modules WHERE unixname='" . $this->modulename . "'"); ! if(@mysql_num_rows($query) == 1) { $MPCONF['MOD'] = @mysql_fetch_array($query); ! } ! if($MPCONF['MOD']['filename'] == '') { ! header("Location: " . $MPCONF['GEN']['uri'] . "/error.php?ecode=usemod"); ! } ! if($MPCONF['MOD']['active'] != 1) { ! header("Location: " . $MPCONF['GEN']['uri'] . "/error.php?ecode=activemod"); ! } } } *************** *** 74,92 **** $Module->Init(); - // Start The Page $Template->PrintHeader( array(PAGETITLE => ".::" . $Module->pagetitle . "::.") ); ! ! // Display The Left Side $Template->CreateSide('left'); - // Start The Main Section $Template->Blocking('BeginMain'); ! $Module->MakeContent(); - // End The Main Section $Template->Blocking('EndMain'); - // Display The Right Side, If Wanted On Page $Template->CreateSide('right'); --- 75,88 ---- $Module->Init(); $Template->PrintHeader( array(PAGETITLE => ".::" . $Module->pagetitle . "::.") ); ! $Template->CreateSide('left'); $Template->Blocking('BeginMain'); ! $Module->MakeContent(); $Template->Blocking('EndMain'); $Template->CreateSide('right'); |