Upload
This commit is contained in:
42 files changed
+4036
No files matched your search
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/*-----------------------------------------------------------------------------
|
||||
|
||||
orblog - Simple blog for hidden networks.
|
||||
|
||||
Version: 0.1
|
||||
Git: https://git.runx.zip/chicory/orblog-legacy
|
||||
Copyright: chicory@runx.zip 2020
|
||||
License: http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
-----------------------------------------------------------------------------*/
|
||||
|
||||
include_once 'config.php';
|
||||
include_once 'private/libs/functions.php';
|
||||
include_once 'private/libs/parsedown.php';
|
||||
include_once 'private/languages/'.LANG.'.php';
|
||||
|
||||
error_reporting(0);
|
||||
date_default_timezone_set('UTC');
|
||||
session_name('SESSID');
|
||||
session_start();
|
||||
|
||||
$sqlite = new SQLite3(DATABASE);
|
||||
|
||||
$category_dump = $sqlite -> query('SELECT * FROM `categories`
|
||||
ORDER BY `sort` ASC');
|
||||
if (!empty($_GET['view'])) {
|
||||
$view = preg_replace("/[^a-zA-Z_\-\d]/ui", "", $_GET['view']);
|
||||
|
||||
if (file_exists('private/pages/'.$view.'.php')) {
|
||||
include 'private/pages/'.$view.'.php';
|
||||
} else {
|
||||
include 'private/pages/404.php';
|
||||
}
|
||||
} else {
|
||||
include 'private/pages/index.php';
|
||||
}
|
||||
|
||||
$_TPL['category_list'] = view_categories($category_dump);
|
||||
include_template('footer');
|
||||
Reference in new issue
Block a user