remove class_exists wrapper for class definitions
This commit is contained in:
parent
22850ae94e
commit
0782a971cc
|
|
@ -26,11 +26,7 @@
|
|||
|
||||
/**
|
||||
* destinations
|
||||
*
|
||||
* @method get_array get the destinations
|
||||
* @method select build the html select
|
||||
*/
|
||||
if (!class_exists('destinations')) {
|
||||
class destinations {
|
||||
|
||||
/**
|
||||
|
|
@ -455,26 +451,7 @@ if (!class_exists('destinations')) {
|
|||
$destination_id = str_replace("[", "_", $destination_id);
|
||||
//$destination_id = preg_replace('/[^a-zA-Z_,.]/', '', $destination_name);
|
||||
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
function get_destinations(id, destination_type, action, search) {
|
||||
//alert(action);
|
||||
var xhttp = new XMLHttpRequest();
|
||||
xhttp.onreadystatechange = function() {
|
||||
if (this.readyState == 4 && this.status == 200) {
|
||||
document.getElementById(id).innerHTML = this.responseText;
|
||||
}
|
||||
};
|
||||
if (action) {
|
||||
xhttp.open("GET", "/app/destinations/resources/destinations.php?destination_type="+destination_type+"&action="+action, true);
|
||||
}
|
||||
else {
|
||||
xhttp.open("GET", "/app/destinations/resources/destinations.php?destination_type="+destination_type, true);
|
||||
}
|
||||
xhttp.send();
|
||||
}
|
||||
</script>
|
||||
<?php
|
||||
|
||||
|
||||
//get the destinations
|
||||
$destinations = $this->get($destination_type);
|
||||
|
|
@ -1308,7 +1285,7 @@ if (!class_exists('destinations')) {
|
|||
} //method
|
||||
|
||||
} //class
|
||||
}
|
||||
|
||||
/*
|
||||
$obj = new destinations;
|
||||
//$destinations = $obj->destinations;
|
||||
|
|
@ -1319,5 +1296,3 @@ echo $obj->select('ivr', 'example4', '');
|
|||
echo $obj->select('ivr', 'example5', '');
|
||||
echo $obj->select('ivr', 'example6', '');
|
||||
*/
|
||||
|
||||
?>
|
||||
|
|
|
|||
Loading…
Reference in New Issue