From 481c4f37cce393399e6508af4f4eb078915c781c Mon Sep 17 00:00:00 2001 From: mcrane Date: Sat, 21 Feb 2009 14:33:38 -0700 Subject: phpservice additional work on php script delete --- config/phpservice/phpservice.xml | 2 +- config/phpservice/phpservice_php_edit.tmp | 25 ++++++++++++------------- 2 files changed, 13 insertions(+), 14 deletions(-) (limited to 'config/phpservice') diff --git a/config/phpservice/phpservice.xml b/config/phpservice/phpservice.xml index e4cff8bc..225590b8 100644 --- a/config/phpservice/phpservice.xml +++ b/config/phpservice/phpservice.xml @@ -41,7 +41,7 @@ Describe your package requirements here Currently there are no FAQ items provided. PHP Service Settings - 0.3 + 0.4.1 Settings /usr/local/pkg/phpservice.inc diff --git a/config/phpservice/phpservice_php_edit.tmp b/config/phpservice/phpservice_php_edit.tmp index 2f0a64af..411cc5f4 100644 --- a/config/phpservice/phpservice_php_edit.tmp +++ b/config/phpservice/phpservice_php_edit.tmp @@ -39,6 +39,18 @@ if (isset($_POST['id'])) { $id = $_POST['id']; } +if ($_GET['act'] == "del") { + if ($_GET['type'] == 'php') { + if ($a_phpservice[$_GET['id']]) { + unset($a_phpservice[$_GET['id']]); + write_config(); + php_sync_package(); + header("Location: phpservice_php.php"); + exit; + } + } +} + if (isset($id) && $a_phpservice[$id]) { $pconfig['name'] = $a_phpservice[$id]['name']; @@ -48,23 +60,10 @@ if (isset($id) && $a_phpservice[$id]) { } - if ($_POST) { unset($input_errors); $pconfig = $_POST; - - if ($_GET['act'] == "del") { - if ($_GET['type'] == 'php') { - if ($a_phpservice[$_GET['id']]) { - unset($a_phpservice[$_GET['id']]); - write_config(); - php_sync_package(); - header("Location: phpservice_php.php"); - exit; - } - } - } if (!$input_errors) { -- cgit v1.2.3