浏览代码

Update contact_phone_edit.php

FusionPBX 8 年之前
父节点
当前提交
5c4e1b6f2f
共有 1 个文件被更改,包括 19 次插入13 次删除
  1. 19 13
      contact_phone_edit.php

+ 19 - 13
contact_phone_edit.php

@@ -24,16 +24,20 @@
 	Mark J Crane <[email protected]>
 	Luis Daniel Lucio Quiroz <[email protected]>
 */
-require_once "root.php";
-require_once "resources/require.php";
-require_once "resources/check_auth.php";
-if (permission_exists('contact_phone_edit') || permission_exists('contact_phone_add')) {
-	//access granted
-}
-else {
-	echo "access denied";
-	exit;
-}
+
+//includes
+	require_once "root.php";
+	require_once "resources/require.php";
+	require_once "resources/check_auth.php";
+	
+//check permissions
+	if (permission_exists('contact_phone_edit') || permission_exists('contact_phone_add')) {
+		//access granted
+	}
+	else {
+		echo "access denied";
+		exit;
+	}
 
 //add multi-lingual support
 	$language = new text;
@@ -48,9 +52,10 @@ else {
 		$action = "add";
 	}
 
-if (strlen($_GET["contact_uuid"]) > 0) {
-	$contact_uuid = check_str($_GET["contact_uuid"]);
-}
+//get the uuid
+	if (strlen($_GET["contact_uuid"]) > 0) {
+		$contact_uuid = check_str($_GET["contact_uuid"]);
+	}
 
 //get http post variables and set them to php variables
 	if (count($_POST)>0) {
@@ -360,4 +365,5 @@ if (strlen($_GET["contact_uuid"]) > 0) {
 
 //include the footer
 	require_once "resources/footer.php";
+
 ?>