Change pathname style from {} to .
Instability seen when pathnames with globals enclosed in {} - revert to . style pathnames
This commit is contained in:
parent
3ea36f5459
commit
e313b9da3f
|
@ -923,7 +923,7 @@ function Setup_RealTime()
|
||||||
|
|
||||||
function addDriver($sccp_compatible) {
|
function addDriver($sccp_compatible) {
|
||||||
outn("<li>" . _("Adding driver ...") . "</li>");
|
outn("<li>" . _("Adding driver ...") . "</li>");
|
||||||
$file = "{$_SERVER['DOCUMENT_ROOT']}/admin/modules/core/functions.inc/drivers/Sccp.class.php";
|
$file = $_SERVER['DOCUMENT_ROOT'] . '/admin/modules/core/functions.inc/drivers/Sccp.class.php';
|
||||||
$contents = "<?php include '/var/www/html/admin/modules/sccp_manager/sccpManClasses/Sccp.class.php.v{$sccp_compatible}'; ?>";
|
$contents = "<?php include '/var/www/html/admin/modules/sccp_manager/sccpManClasses/Sccp.class.php.v{$sccp_compatible}'; ?>";
|
||||||
file_put_contents($file, $contents);
|
file_put_contents($file, $contents);
|
||||||
|
|
||||||
|
@ -931,7 +931,7 @@ function addDriver($sccp_compatible) {
|
||||||
$dir = $cnf_int->get('ASTETCDIR');
|
$dir = $cnf_int->get('ASTETCDIR');
|
||||||
if (!file_exists("{$dir}/sccp.conf")) { // System re Config
|
if (!file_exists("{$dir}/sccp.conf")) { // System re Config
|
||||||
outn("<li>" . _("Adding default configuration file ...") . "</li>");
|
outn("<li>" . _("Adding default configuration file ...") . "</li>");
|
||||||
$sccpfile = file_get_contents("{$_SERVER['DOCUMENT_ROOT']}/admin/modules/sccp_manager/conf/sccp.conf");
|
$sccpfile = file_get_contents($_SERVER['DOCUMENT_ROOT'] . '/admin/modules/sccp_manager/conf/sccp.conf');
|
||||||
file_put_contents("{$dir}/sccp.conf", $sccpfile);
|
file_put_contents("{$dir}/sccp.conf", $sccpfile);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1044,7 +1044,7 @@ function cleanUpSccpSettings() {
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Clean up sccpsettings to remove legacy values.
|
// Clean up sccpsettings to remove legacy values.
|
||||||
$xml_vars = "{$_SERVER['DOCUMENT_ROOT']}/admin/modules/sccp_manager/conf/sccpgeneral.xml.v{$sccp_compatible}";
|
$xml_vars = $_SERVER['DOCUMENT_ROOT'] . '/admin/modules/sccp_manager/conf/sccpgeneral.xml.v{$sccp_compatible}';
|
||||||
$thisInstaller->xml_data = simplexml_load_file($xml_vars);
|
$thisInstaller->xml_data = simplexml_load_file($xml_vars);
|
||||||
$thisInstaller->initVarfromXml();
|
$thisInstaller->initVarfromXml();
|
||||||
foreach ( array_diff_key($settingsFromDb,$thisInstaller->sccpvalues) as $key => $valueArray) {
|
foreach ( array_diff_key($settingsFromDb,$thisInstaller->sccpvalues) as $key => $valueArray) {
|
||||||
|
|
|
@ -352,7 +352,7 @@ class extconfigs
|
||||||
}
|
}
|
||||||
// TODO: Need to add index.cnf, after setting defaults correctly
|
// TODO: Need to add index.cnf, after setting defaults correctly
|
||||||
if (!file_exists("{$baseConfig['tftp_templates_path']}/XMLDefault.cnf.xml_template")) {
|
if (!file_exists("{$baseConfig['tftp_templates_path']}/XMLDefault.cnf.xml_template")) {
|
||||||
$src_path = "{$_SERVER['DOCUMENT_ROOT']}/admin/modules/sccp_manager/conf/";
|
$src_path = $_SERVER['DOCUMENT_ROOT'] . '/admin/modules/sccp_manager/conf/';
|
||||||
$dst_path = "{$baseConfig["tftp_templates_path"]}/";
|
$dst_path = "{$baseConfig["tftp_templates_path"]}/";
|
||||||
foreach (glob("{$src_path}*.*_template") as $filename) {
|
foreach (glob("{$src_path}*.*_template") as $filename) {
|
||||||
copy($filename, $dst_path . basename($filename));
|
copy($filename, $dst_path . basename($filename));
|
||||||
|
|
Loading…
Reference in a new issue