diff --git a/sip_enrollment.phtml b/sip_enrollment.phtml
index 0947188..82e471f 100644
--- a/sip_enrollment.phtml
+++ b/sip_enrollment.phtml
@@ -1,19 +1,20 @@
createAccount();
?>
diff --git a/sip_settings.phtml b/sip_settings.phtml
index 97f65d0..dabf6c6 100644
--- a/sip_settings.phtml
+++ b/sip_settings.phtml
@@ -1,118 +1,119 @@
"CDRTool_Session",
- "auth" => "CDRTool_Auth",
- "perm" => "CDRTool_Perm"));
+ array(
+ "sess" => "CDRTool_Session",
+ "auth" => "CDRTool_Auth",
+ "perm" => "CDRTool_Perm"
+ )
+ );
$account = $_REQUEST['account'];
$reseller = $_REQUEST['reseller'];
$customer = $_REQUEST['customer'];
$sip_engine = $_REQUEST['sip_engine'];
if ($reseller && !$customer) {
$customer = $reseller;
} else if ($customer && !$reseller) {
$reseller = $customer;
}
$perm->check("provisioning");
- global $CDRTool;
+ global $CDRTool;
if ($CDRTool['impersonate']) {
- if (preg_match("/^([1-9][0-9]*)\.([1-9][0-9]*)$/",$CDRTool['impersonate'],$m)) {
- $_customer=$m[1];
- $_reseller=$m[2];
+ if (preg_match("/^([1-9][0-9]*)\.([1-9][0-9]*)$/", $CDRTool['impersonate'], $m)) {
+ $_customer = $m[1];
+ $_reseller = $m[2];
if ($_customer == $_reseller) {
$login_type = 'reseller';
} else {
$login_type = 'customer';
}
$login_credentials=array(
- 'customer' => $_customer,
- 'reseller' => $_reseller,
- 'login_type' => $login_type
- );
-
+ 'customer' => $_customer,
+ 'reseller' => $_reseller,
+ 'login_type' => $login_type
+ );
} else if ($CDRTool['impersonate'] == '0' || $CDRTool['impersonate'] = '0.0') {
- $login_credentials=array(
- 'customer' => $customer,
- 'reseller' => $reseller,
- 'login_type' => 'admin'
- );
+ $login_credentials = array(
+ 'customer' => $customer,
+ 'reseller' => $reseller,
+ 'login_type' => 'admin'
+ );
} else {
page_close();
- printf ("Error: Invalid impersonate value %s",$CDRTool['impersonate']);
+ printf("Error: Invalid impersonate value %s", $CDRTool['impersonate']);
exit;
}
-
} else {
- page_close();
- printf ("Error: Missing impersonate setting");
- exit;
+ page_close();
+ printf("Error: Missing impersonate setting");
+ exit;
}
-
} else {
- page_open(array("sess" => "SIP_Subscriber_Session",
- "auth" => "SIP_Subscriber_Auth")
- );
- $account = $SIP['account'];
- $reseller = $SIP['reseller'];
- $customer = $SIP['customer'];
- $sip_engine = $SIP['engine'];
- $login_type = "subscriber";
+ page_open(
+ array(
+ "sess" => "SIP_Subscriber_Session",
+ "auth" => "SIP_Subscriber_Auth"
+ )
+ );
+ $account = $SIP['account'];
+ $reseller = $SIP['reseller'];
+ $customer = $SIP['customer'];
+ $sip_engine = $SIP['engine'];
+ $login_type = "subscriber";
$login_credentials=array(
- 'login_type' => $login_type,
- 'customer' => $customer,
- 'reseller' => $reseller,
- 'sip_engine' => $sip_engine
- );
-
+ 'login_type' => $login_type,
+ 'customer' => $customer,
+ 'reseller' => $reseller,
+ 'sip_engine' => $sip_engine
+ );
}
-$_class='SipSettings';
-$_reseller_class=$_class.$reseller;
+$_class = 'SipSettings';
+$_reseller_class = $_class.$reseller;
if (class_exists($_reseller_class)) {
- $SipSettings_class=$_reseller_class;
+ $SipSettings_class=$_reseller_class;
} else {
- $SipSettings_class=$_class;
+ $SipSettings_class=$_class;
}
if ($resellerFilters[$login_credentials['reseller']]['sip_engine']) {
- $login_credentials['sip_engine'] = $resellerFilters[$login_credentials['reseller']]['sip_engine'];
+ $login_credentials['sip_engine'] = $resellerFilters[$login_credentials['reseller']]['sip_engine'];
} else if ($_REQUEST['sip_engine']) {
- $login_credentials['sip_engine']=$_REQUEST['sip_engine'];
+ $login_credentials['sip_engine'] = $_REQUEST['sip_engine'];
} else if ($resellerFilters['default']['sip_engine']) {
- $login_credentials['sip_engine'] = $resellerFilters['default']['sip_engine'];
+ $login_credentials['sip_engine'] = $resellerFilters['default']['sip_engine'];
}
-renderUI($SipSettings_class,$account,$login_credentials,$soapEngines);
+renderUI($SipSettings_class, $account, $login_credentials, $soapEngines);
page_close();
?>
diff --git a/sip_settings_digest.phtml b/sip_settings_digest.phtml
index 5e87823..49cbe82 100644
--- a/sip_settings_digest.phtml
+++ b/sip_settings_digest.phtml
@@ -1,49 +1,48 @@
$reseller,
- 'customer' => $customer,
- 'login_type' => $login_type,
- 'sip_engine' => $sip_engine,
- 'templates_path' => './templates'
-
+$login_credentials = array(
+ 'reseller' => $reseller,
+ 'customer' => $customer,
+ 'login_type' => $login_type,
+ 'sip_engine' => $sip_engine,
+ 'templates_path' => './templates'
);
-renderUI($SipSettings_class,$account,$login_credentials,$soapEngines);
+renderUI($SipSettings_class, $account, $login_credentials, $soapEngines);
?>
diff --git a/sip_settings_tlscert.phtml b/sip_settings_tlscert.phtml
index 53b950e..f864993 100644
--- a/sip_settings_tlscert.phtml
+++ b/sip_settings_tlscert.phtml
@@ -1,45 +1,44 @@
$reseller,
- 'customer' => $customer,
- 'login_type' => $login_type,
- 'sip_engine' => $sip_engine,
- 'templates_path' => './templates'
-
+$login_credentials = array(
+ 'reseller' => $reseller,
+ 'customer' => $customer,
+ 'login_type' => $login_type,
+ 'sip_engine' => $sip_engine,
+ 'templates_path' => './templates'
);
-renderUI($SipSettings_class,$account,$login_credentials,$soapEngines);
+renderUI($SipSettings_class, $account, $login_credentials, $soapEngines);
?>