mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-27 22:33:10 +09:00
Convert all instances of _XE_PATH_, __XE_VERSION__, etc. to Rhymix constants
_XE_PATH_ -> RX_BASEDIR __XE_VERSION__ -> RX_VERSION
This commit is contained in:
parent
4fdb51d689
commit
b0f66a36c5
43 changed files with 104 additions and 105 deletions
|
|
@ -181,7 +181,7 @@ class adminAdminController extends admin
|
|||
|
||||
public function updateDefaultDesignInfo($vars)
|
||||
{
|
||||
$siteDesignPath = _XE_PATH_ . 'files/site_design/';
|
||||
$siteDesignPath = RX_BASEDIR . 'files/site_design/';
|
||||
|
||||
$vars->module_skin = json_decode($vars->module_skin);
|
||||
|
||||
|
|
@ -190,7 +190,7 @@ class adminAdminController extends admin
|
|||
FileHandler::makeDir($siteDesignPath);
|
||||
}
|
||||
|
||||
$siteDesignFile = _XE_PATH_ . 'files/site_design/design_' . $vars->site_srl . '.php';
|
||||
$siteDesignFile = RX_BASEDIR . 'files/site_design/design_' . $vars->site_srl . '.php';
|
||||
|
||||
$layoutTarget = 'layout_srl';
|
||||
$skinTarget = 'skin';
|
||||
|
|
@ -255,7 +255,7 @@ class adminAdminController extends admin
|
|||
}
|
||||
}
|
||||
|
||||
$siteDesignFile = _XE_PATH_ . 'files/site_design/design_' . $site_srl . '.php';
|
||||
$siteDesignFile = RX_BASEDIR . 'files/site_design/design_' . $site_srl . '.php';
|
||||
FileHandler::writeFile($siteDesignFile, implode(PHP_EOL, $buff));
|
||||
}
|
||||
|
||||
|
|
@ -324,7 +324,7 @@ class adminAdminController extends admin
|
|||
{
|
||||
if($favorite->type == 'module')
|
||||
{
|
||||
$modulePath = _XE_PATH_ . 'modules/' . $favorite->module;
|
||||
$modulePath = RX_BASEDIR . 'modules/' . $favorite->module;
|
||||
if(!is_dir($modulePath))
|
||||
{
|
||||
$deleteTargets[] = $favorite->admin_favorite_srl;
|
||||
|
|
@ -396,7 +396,7 @@ class adminAdminController extends admin
|
|||
$oModuleModel = getModel('module');
|
||||
$oAdminConfig = $oModuleModel->getModuleConfig('admin');
|
||||
|
||||
Rhymix\Framework\Storage::delete(_XE_PATH_ . $oAdminConfig->adminLogo);
|
||||
Rhymix\Framework\Storage::delete(RX_BASEDIR . $oAdminConfig->adminLogo);
|
||||
unset($oAdminConfig->adminLogo);
|
||||
|
||||
$oModuleController = getController('module');
|
||||
|
|
@ -460,10 +460,10 @@ class adminAdminController extends admin
|
|||
}
|
||||
|
||||
$iconname = Context::get('iconname');
|
||||
$file_exist = FileHandler::readFile(_XE_PATH_ . 'files/attach/xeicon/' . $virtual_site . $iconname);
|
||||
$file_exist = FileHandler::readFile(RX_BASEDIR . 'files/attach/xeicon/' . $virtual_site . $iconname);
|
||||
if($file_exist)
|
||||
{
|
||||
@Rhymix\Framework\Storage::delete(_XE_PATH_ . 'files/attach/xeicon/' . $virtual_site . $iconname);
|
||||
@Rhymix\Framework\Storage::delete(RX_BASEDIR . 'files/attach/xeicon/' . $virtual_site . $iconname);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -52,8 +52,8 @@ class adminAdminModel extends admin
|
|||
FileHandler::writeFile('./files/cache/ftp_check', $pin);
|
||||
|
||||
// create path candidate
|
||||
$xe_path = _XE_PATH_;
|
||||
$path_info = array_reverse(explode('/', _XE_PATH_));
|
||||
$xe_path = RX_BASEDIR;
|
||||
$path_info = array_reverse(explode('/', RX_BASEDIR));
|
||||
array_pop($path_info); // remove last '/'
|
||||
$path_candidate = array();
|
||||
|
||||
|
|
@ -127,8 +127,8 @@ class adminAdminModel extends admin
|
|||
FileHandler::writeFile('./files/cache/ftp_check', $pin);
|
||||
|
||||
// create path candidate
|
||||
$xe_path = _XE_PATH_;
|
||||
$path_info = array_reverse(explode('/', _XE_PATH_));
|
||||
$xe_path = RX_BASEDIR;
|
||||
$path_info = array_reverse(explode('/', RX_BASEDIR));
|
||||
array_pop($path_info); // remove last '/'
|
||||
$path_candidate = array();
|
||||
|
||||
|
|
@ -175,7 +175,7 @@ class adminAdminModel extends admin
|
|||
*/
|
||||
function getAdminFTPPath()
|
||||
{
|
||||
Context::loadLang(_XE_PATH_ . 'modules/autoinstall/lang');
|
||||
Context::loadLang(RX_BASEDIR . 'modules/autoinstall/lang');
|
||||
@set_time_limit(5);
|
||||
|
||||
$ftp_info = Context::getRequestVars();
|
||||
|
|
@ -229,8 +229,8 @@ class adminAdminModel extends admin
|
|||
FileHandler::writeFile('./files/cache/ftp_check', $pin);
|
||||
|
||||
// create path candidate
|
||||
$xe_path = _XE_PATH_;
|
||||
$path_info = array_reverse(explode('/', _XE_PATH_));
|
||||
$xe_path = RX_BASEDIR;
|
||||
$path_info = array_reverse(explode('/', RX_BASEDIR));
|
||||
array_pop($path_info); // remove last '/'
|
||||
$path_candidate = array();
|
||||
|
||||
|
|
@ -319,7 +319,7 @@ class adminAdminModel extends admin
|
|||
*/
|
||||
function getAdminFTPList()
|
||||
{
|
||||
Context::loadLang(_XE_PATH_ . 'modules/autoinstall/lang');
|
||||
Context::loadLang(RX_BASEDIR . 'modules/autoinstall/lang');
|
||||
@set_time_limit(5);
|
||||
|
||||
$ftp_info = Context::getRequestVars();
|
||||
|
|
@ -391,7 +391,7 @@ class adminAdminModel extends admin
|
|||
*/
|
||||
function getThemeList()
|
||||
{
|
||||
$path = _XE_PATH_ . 'themes';
|
||||
$path = RX_BASEDIR . 'themes';
|
||||
$list = FileHandler::readDir($path);
|
||||
|
||||
$theme_info = array();
|
||||
|
|
@ -419,7 +419,7 @@ class adminAdminModel extends admin
|
|||
return $GLOBALS['__ThemeInfo__'][$theme_name];
|
||||
}
|
||||
|
||||
$info_file = _XE_PATH_ . 'themes/' . $theme_name . '/conf/info.xml';
|
||||
$info_file = RX_BASEDIR . 'themes/' . $theme_name . '/conf/info.xml';
|
||||
if(!file_exists($info_file))
|
||||
{
|
||||
return;
|
||||
|
|
@ -599,7 +599,7 @@ class adminAdminModel extends admin
|
|||
$oModuleModel = getModel('module');
|
||||
foreach($searched_list as $val)
|
||||
{
|
||||
$skin_list = $oModuleModel->getSkins(_XE_PATH_ . 'modules/' . $val);
|
||||
$skin_list = $oModuleModel->getSkins(RX_BASEDIR . 'modules/' . $val);
|
||||
|
||||
if(is_array($skin_list) && count($skin_list) > 0 && !in_array($val, $exceptionModule))
|
||||
{
|
||||
|
|
@ -769,7 +769,7 @@ class adminAdminModel extends admin
|
|||
|
||||
foreach($list as $k => $v)
|
||||
{
|
||||
if(!is_dir(_XE_PATH_ . 'modules/' . $v->module))
|
||||
if(!is_dir(RX_BASEDIR . 'modules/' . $v->module))
|
||||
{
|
||||
unset($list[$k]);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -213,7 +213,7 @@ class adminAdminView extends admin
|
|||
// move from index method, because use in admin footer
|
||||
/*
|
||||
$newest_news_url = sprintf("http://news.xpressengine.com/%s/news.php?version=%s&package=%s", _XE_LOCATION_, __XE_VERSION__, _XE_PACKAGE_);
|
||||
$cache_file = sprintf("%sfiles/cache/newest_news.%s.cache.php", _XE_PATH_, _XE_LOCATION_);
|
||||
$cache_file = sprintf("%sfiles/cache/newest_news.%s.cache.php", RX_BASEDIR, _XE_LOCATION_);
|
||||
if(!file_exists($cache_file) || filemtime($cache_file) + 60 * 60 < $_SERVER['REQUEST_TIME'])
|
||||
{
|
||||
// Considering if data cannot be retrieved due to network problem, modify filemtime to prevent trying to reload again when refreshing administration page
|
||||
|
|
|
|||
|
|
@ -48,9 +48,9 @@
|
|||
<div class="x_control-group">
|
||||
<label class="x_control-label" for="ftp_path">{$lang->msg_ftp_installed_ftp_realpath}</label>
|
||||
<div class="x_controls">
|
||||
<input type="text" name="ftp_path" id="ftp_path" style="min-width:90%" value="{$ftp_info['path'] ?: _XE_PATH_}" />
|
||||
<input type="text" name="ftp_path" id="ftp_path" style="min-width:90%" value="{$ftp_info['path'] ?: \RX_BASEDIR}" />
|
||||
<br />
|
||||
<p class="x_help-block">{$lang->msg_ftp_autodetected_ftp_realpath} : {_XE_PATH_}</p>
|
||||
<p class="x_help-block">{$lang->msg_ftp_autodetected_ftp_realpath} : {\RX_BASEDIR}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="x_control-group">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue