mirror of
https://github.com/FOSSBilling/FOSSBilling.git
synced 2026-12-06 15:14:20 +09:00
Rename htaccess file in source code and automatically name it when required during install
This commit is contained in:
1 parent
26a5165a89
commit
99db52cef6
3 files changed
+8
-1
No files matched your search
@@ -18,7 +18,7 @@
|
||||
<include name="bb-data/cache"/>
|
||||
<include name="bb-data/uploads"/>
|
||||
<include name="bb-data/index.html"/>
|
||||
<include name="bb-data/.htaccess"/>
|
||||
<include name="bb-data/.htaccess.txt"/>
|
||||
|
||||
<exclude name="bb-data/log/*"/>
|
||||
<exclude name="bb-data/cache/*"/>
|
||||
|
||||
File renamed without changes.
@@ -39,6 +39,9 @@ define('BB_PATH_CONFIG', BB_PATH_ROOT . '/bb-config.php');
|
||||
define('BB_PATH_CRON', BB_PATH_ROOT . '/bb-cron.php');
|
||||
define('BB_PATH_LANGS', BB_PATH_ROOT . '/bb-locale');
|
||||
|
||||
define('BB_PATH_HTACCESS', BB_PATH_ROOT . '/.htaccess');
|
||||
define('BB_PATH_HTACCESS_TEMPLATE', BB_PATH_ROOT . '/.htaccess.txt');
|
||||
|
||||
// Ensure library/ is on include_path
|
||||
set_include_path(implode(PATH_SEPARATOR, [
|
||||
BB_PATH_LIBRARY,
|
||||
@@ -315,6 +318,10 @@ final class Box_Installer
|
||||
// E-mail was not sent, but that is not a problem
|
||||
error_log($e->getMessage());
|
||||
}
|
||||
|
||||
if(!file_exists(BB_PATH_HTACCESS) && file_exists(BB_PATH_HTACCESS_TEMPLATE)) {
|
||||
rename(BB_PATH_HTACCESS_TEMPLATE, BB_PATH_HTACCESS);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user