diff options
author | Freya Murphy <freya@freyacat.org> | 2024-03-30 12:14:42 -0400 |
---|---|---|
committer | Freya Murphy <freya@freyacat.org> | 2024-03-30 12:14:42 -0400 |
commit | 1f04b83be337cc91a3fabcf4e574e2306f3d2eaa (patch) | |
tree | 74d7d65a7047e60d1877384e3c7b0d70c7b0e49a /web/core/model.php | |
parent | start database (user and post), and initial barebones home page (diff) | |
download | xssbook2-1f04b83be337cc91a3fabcf4e574e2306f3d2eaa.tar.gz xssbook2-1f04b83be337cc91a3fabcf4e574e2306f3d2eaa.tar.bz2 xssbook2-1f04b83be337cc91a3fabcf4e574e2306f3d2eaa.zip |
refactor
Diffstat (limited to '')
-rw-r--r-- | web/core/model.php | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/web/core/model.php b/web/core/model.php deleted file mode 100644 index 039b138..0000000 --- a/web/core/model.php +++ /dev/null @@ -1,29 +0,0 @@ -<?php /* Copyright (c) 2024 Freya Murphy */ -abstract class Model { - // the main model - // shared by all controllers and models - public $main; - public $load; - - // the database - public $db; - - private $config; - - function __construct() { - $this->main = $GLOBALS['__vars']['main']; - $this->load = $GLOBALS['__vars']['load']; - $this->db = $this->main->db; - $this->config = new Aesthetic(); - } - - public function get_data() { - $data = array(); - $route = $this->main->info['route']; - $files = $this->config->get_files($route); - $data = array_merge($data, $files); - $data['self'] = $this->main->user(); - return $data; - } -} -?> |