Update the example code to set MOH. Add the auto_loader class only if it is not defined.

This commit is contained in:
Mark Crane 2014-12-24 06:36:09 +00:00
parent cef63582d0
commit f5c7e7038b
2 changed files with 29 additions and 27 deletions

View File

@ -201,10 +201,10 @@ include "root.php";
}
}
//require_once "app/music_on_hold/resources/classes/switch_music_on_hold.php";
//$moh= new switch_music_on_hold;
//$moh->select_name = "hold_music";
//$moh->select_value = $hold_music;
//echo $moh->select();
//build and save the XML
//require_once "app/music_on_hold/resources/classes/switch_music_on_hold.php";
//$moh = new switch_music_on_hold;
//$moh->xml();
//$moh->save();
?>

View File

@ -42,6 +42,7 @@
}
//class auto loader
if (!class_exists(auto_loader)) {
class auto_loader {
public function __construct() {
spl_autoload_register(array($this, 'loader'));
@ -67,6 +68,7 @@
unset($results);
}
}
}
$autoload = new auto_loader();
//define variable(s)