0
0

Minor changes

Moved config into $GLOBALS
Moved request_uri into $GLOBALS
Modified all files accordingly
Modified logout page for future improvements (not deleting the entire $_SESSION)
Fixed LICENSEs, moved LICENSE for PHP files in /lib/php subfolder instead of /lib
This commit is contained in:
Bryan
2019-04-06 11:57:35 +02:00
parent 18dc9b18d3
commit 81d21c311f
11 changed files with 30 additions and 29 deletions

View File

@@ -1,7 +1,7 @@
<?php
require_once ( 'lib/php/classes/Database.php' );
function split_uri_array ( string $php_self, string $request_uri ) : Array {
$uri = substr ( $request_uri, strlen ( substr ( $php_self, 0, strrpos ( $php_self, 'index.php' ) ) ), strlen ( $request_uri ) - strlen ( substr ( $php_self, 0, strrpos ( $php_self, 'index.php' ) ) ) );
function split_uri_array ( ) : Array {
$uri = substr ( $_SERVER [ 'REQUEST_URI' ], strlen ( substr ( $_SERVER [ 'REQUEST_URI' ], 0, strrpos ( $_SERVER [ 'REQUEST_URI' ], 'index.php' ) ) ), strlen ( $_SERVER [ 'REQUEST_URI' ] ) - strlen ( substr ( $_SERVER [ 'REQUEST_URI' ], 0, strrpos ( $_SERVER [ 'REQUEST_URI' ], 'index.php' ) ) ) );
$arr = Array ( );
$last_arg_pos = 0;
if ( substr ( $uri, strlen ( $uri ) - 1, 1 ) == "/" ) {
@@ -22,4 +22,3 @@
$config [ 'installation_path' ] = $_SERVER [ 'DOCUMENT_ROOT' ] . $config [ 'installation_path' ];
return $config;
}
?>