From 666ccddb3436145bb795b8861b7cfabd151fd29f Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Fri, 8 Jul 2016 10:32:56 -0600 Subject: [PATCH] Update app_defaults.php Music on hold import from XML strip the domain name and rate from the name. --- app/music_on_hold/app_defaults.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/music_on_hold/app_defaults.php b/app/music_on_hold/app_defaults.php index c58f2f7a04..fed1a45694 100644 --- a/app/music_on_hold/app_defaults.php +++ b/app/music_on_hold/app_defaults.php @@ -66,6 +66,11 @@ $$name = $p['@attributes']['value']; $attributes[] = $name; } + + //strip the domain name and rate from the name + $array = explode('/', $stream_name); + if (count($array) == 3) { $stream_name = $array[1]; } + if (count($array) == 2) { $stream_name = $array[0]; } //insert the data into the database $music_on_hold_uuid = uuid();