Update switch_music_on_hold.php

Add missing forward slashes so the pattern will be correct for the preg_replace.
This commit is contained in:
FusionPBX 2016-05-25 17:42:56 -06:00
parent a25c9a3e48
commit 3ce93c654c
1 changed files with 3 additions and 3 deletions

View File

@ -192,8 +192,8 @@ include "root.php";
$default_moh_prefix = 'music';
}
//replace the variables
$file_contents = preg_replace("music\/default", $default_moh_prefix, $file_contents);
$file_contents = preg_replace("[\t ]*(?:<!--)?{v_moh_categories}(?:-->)?", $this->xml, $file_contents);
$file_contents = preg_replace("/music\/default/", $default_moh_prefix, $file_contents);
$file_contents = preg_replace("/[\t ]*(?:<!--)?{v_moh_categories}(?:-->)?/", $this->xml, $file_contents);
//write the XML config file
$fout = fopen($_SESSION['switch']['conf']['dir']."/autoload_configs/local_stream.conf.xml","w");
@ -212,4 +212,4 @@ include "root.php";
//$moh->xml();
//$moh->save();
?>
?>