diff options
author | neoraider <devnull@localhost> | 2006-01-09 20:49:02 +0100 |
---|---|---|
committer | neoraider <devnull@localhost> | 2006-01-09 20:49:02 +0100 |
commit | 73d5e907a797e976e59f328d4f2fd0b8bfcebde6 (patch) | |
tree | 98108e9738db75d2688de5f7a68c72253c54c450 /code/content.inc.php | |
parent | 61f7b4cc39a399a16298453acbe5a8f49ad0513d (diff) | |
download | neon-73d5e907a797e976e59f328d4f2fd0b8bfcebde6.tar neon-73d5e907a797e976e59f328d4f2fd0b8bfcebde6.zip |
Allgemein ist jetzt alles etwas weiter. Vieles ist jetzt durch Klassen gel?st, und einige andere Teile von Neon sind jetzt besser strukturiert.
Diffstat (limited to 'code/content.inc.php')
-rw-r--r-- | code/content.inc.php | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/code/content.inc.php b/code/content.inc.php index 5fc2d76..c92f1b2 100644 --- a/code/content.inc.php +++ b/code/content.inc.php @@ -3,15 +3,19 @@ define('CONTENT_INC', 1); include('code/db.inc.php'); + include('code/user.inc.php'); + include('code/handlers.inc.php'); function GetPage($name) { $res = DBQuery('SELECT access, handler, data FROM pages WHERE name = ?', $name); - parse_str($res->fields[2], $data); + if(($res->fields[0] & (1 << $GLOBALS['user']->GetGid())) == 0) + return $GLOBALS['handlers'][$res->fields[1]]->HandleErrorMessage('Forbidden', array('page' => $name)); - include('handlers/' . $res->fields[1]); + parse_str($res->fields[2], $data); + $data['_page'] = $name; - return $handlers[$res->fields[1]]($data); + return $GLOBALS['handlers'][$res->fields[1]]->HandleContentData($data); } } ?> |