fix #1 - saving of config files
Dieser Commit ist enthalten in:
Ursprung
3ea22223d6
Commit
f0585f18c2
2 geänderte Dateien mit 7 neuen und 7 gelöschten Zeilen
|
@ -69,15 +69,15 @@ class ModRewrite_ContentController extends ModRewrite_ControllerAbstract {
|
|||
|
||||
if (mr_arrayValue($request, 'checkrootdir') == 1) {
|
||||
// root dir check is enabled, this results in error
|
||||
$sMsg = i18n("The specified directory '%s' does not exists", "cl-mod-rewrite");
|
||||
$sMsg = sprintf($sMsg, $_SERVER['DOCUMENT_ROOT'] . $request['rootdir']);
|
||||
$sMsgTpl = i18n("The specified directory '%s' does not exists", "cl-mod-rewrite");
|
||||
$sMsg = sprintf($sMsgTpl, $_SERVER['DOCUMENT_ROOT'] . $request['rootdir']);
|
||||
$this->_oView->rootdir_error = $this->_notifyBox('error', $sMsg);
|
||||
$bError = true;
|
||||
} else {
|
||||
// root dir check ist disabled, take over the setting and
|
||||
// output a warning.
|
||||
$sMsg = i18n("The specified directory '%s' does not exists in DOCUMENT_ROOT '%s'. This could happen, if clients DOCUMENT_ROOT differs from CONTENIDO backends DOCUMENT_ROOT. However, the setting will be taken over because of disabled check.", "cl-mod-rewrite");
|
||||
$sMsg = sprintf($sMsg, $request['rootdir'], $_SERVER['DOCUMENT_ROOT']);
|
||||
$sMsgTpl = i18n("The specified directory '%s' does not exists in DOCUMENT_ROOT '%s'. This could happen, if clients DOCUMENT_ROOT differs from CONTENIDO backends DOCUMENT_ROOT. However, the setting will be taken over because of disabled check.", "cl-mod-rewrite");
|
||||
$sMsg = sprintf($sMsgTpl, $request['rootdir'], $_SERVER['DOCUMENT_ROOT']);
|
||||
$this->_oView->rootdir_error = $this->_notifyBox('warning', $sMsg);
|
||||
}
|
||||
}
|
||||
|
@ -377,7 +377,7 @@ class ModRewrite_ContentController extends ModRewrite_ControllerAbstract {
|
|||
$this->_oView->content_before .= $this->_notifyBox('info', $sMsg);
|
||||
} else {
|
||||
$sMsg = i18n("Configuration could not saved. Please check write permissions for %s ", "cl-mod-rewrite");
|
||||
$sMsg = sprintf($sMsg, $options['key']);
|
||||
$sMsg = sprintf($sMsg, mr_getConfigurationFilePath($this->_client));
|
||||
$this->_oView->content_before .= $this->_notifyBox('error', $sMsg);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -693,7 +693,7 @@ function mr_setConfiguration($clientId, array $config) {
|
|||
}
|
||||
|
||||
$result = file_put_contents($file, serialize($config));
|
||||
return ($result) ? true : false;
|
||||
return (empty($result)) ? false : true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Laden …
In neuem Issue referenzieren