Skip to content

Commit

Permalink
Should fix use of BASE_URI
Browse files Browse the repository at this point in the history
  • Loading branch information
drAlberT committed Oct 20, 2016
1 parent b6f9385 commit dcc7757
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions config.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,12 @@

ini_set('display_errors', 1);
ini_set('log_errors', 1);
umask(0);

require_once __DIR__.'/vendor/autoload.php';

define('BASE_DIR', __DIR__.'/httpdocs');
define('BASE_URI', rtrim(dirname($_SERVER['PHP_SELF']), '/'));

define('TOOLS_DIR', BASE_DIR.'/tools');
define('TOOLS_URI', BASE_URI.'/tools');

umask(0);

require_once __DIR__.'/vendor/autoload.php';
2 changes: 1 addition & 1 deletion httpdocs/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

$tools = array_map(
function ($item) {
return substr($item, strlen(BASE_DIR));
return BASE_URI.substr($item, strlen(BASE_DIR));
},
array_merge(glob(TOOLS_DIR.'/*', GLOB_ONLYDIR), glob(TOOLS_DIR.'/*.php'))
);
Expand Down

0 comments on commit dcc7757

Please sign in to comment.