-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.php
More file actions
executable file
·40 lines (29 loc) · 967 Bytes
/
index.php
File metadata and controls
executable file
·40 lines (29 loc) · 967 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
#### About ####
/**
* @author SORIA Pierre-Henry
* @email pierrehs@hotmail.com
* @link http://github.com/pH-7
* @copyright Copyright pH7 Script All Rights Reserved.
* @license CC-BY - http://creativecommons.org/licenses/by/3.0/
*/
namespace PH7\Doc;
define('PH7', 1);
include __DIR__ . '/inc/conf.const.php';
include ROOT_PATH . 'inc/scripts/fns.php';
include ROOT_PATH . 'inc/scripts/fns.html.php';
define('LANG', get_lang());
include ROOT_PATH . 'inc/header.tpl.php';
if(!empty($_GET['p'])) {
$sPage = DATA_PATH . LANG . '/' . $_GET['p'] . '.tpl';
if(is_file($sPage)) {
get_page($sPage);
} else {
header('HTTP/1.1 404 Not Found');
get_page(DATA_PATH . LANG . '/core/404-error.tpl');
}
} else {
get_page(DATA_PATH . LANG . '/core/welcome.tpl');
include ROOT_PATH . 'inc/menu.tpl.php';
}
include ROOT_PATH . 'inc/footer.tpl.php';