Merge branch 'master' of github.com:gnuboard/g5

This commit is contained in:
thisgun committed 2017-12-06 19:02:52 +09:00
commit bb9e24d06f
155 files changed
+31784 -31294

No files matched your search

+2 -1
View File
@@ -29,7 +29,8 @@ for ($i=0; $i<$ext_cnt; $i++) {
function g5_path()
{
$result['path'] = str_replace('\\', '/', dirname(__FILE__));
$chroot = substr($_SERVER['SCRIPT_FILENAME'], 0, strpos($_SERVER['SCRIPT_FILENAME'], dirname(__FILE__)));
$result['path'] = str_replace('\\', '/', $chroot.dirname(__FILE__));
$tilde_remove = preg_replace('/^\/\~[^\/]+(.*)$/', '$1', $_SERVER['SCRIPT_NAME']);
$document_root = str_replace($tilde_remove, '', $_SERVER['SCRIPT_FILENAME']);
$pattern = '/' . preg_quote($document_root, '/') . '/i';