small adjustments

This commit is contained in:
slawkens 2023-06-25 08:38:45 +02:00
parent b574a29331
commit 23810345f6
3 changed files with 6 additions and 8 deletions

2
.gitignore vendored
View File

@ -41,7 +41,7 @@ system/cache/*
# php sessions
system/php_sessions/*
!system/php_sessions//index.html
!system/php_sessions/index.html
# logs
system/logs/*

View File

@ -346,12 +346,10 @@ if($load_it)
)) . $content;
}
} else {
$file = TEMPLATES . $template_name . '/pages/' . $page . '.php';
if(!@file_exists($file) || preg_match('/[^A-z0-9_\-]/', $page))
{
$file = SYSTEM . 'pages/' . $page . '.php';
if(!@file_exists($file) || preg_match('/[^A-z0-9_\-]/', $page))
{
$file = TEMPLATES . "$template_name/pages/$page.php";
if(!@file_exists($file) || preg_match('/[^A-z0-9_\-]/', $page)) {
$file = SYSTEM . "pages/$page.php";
if(!@file_exists($file) || preg_match('/[^A-z0-9_\-]/', $page)) {
$page = '404';
$file = SYSTEM . 'pages/404.php';
}

View File

@ -32,6 +32,6 @@ server {
include snippets/fastcgi-php.conf;
fastcgi_read_timeout 240;
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
# for ubuntu 22.04+ it will be php8.1-fpm.-sock
# for ubuntu 22.04+ it will be php8.1-fpm.sock
}
}