From 07c179119bd74d08d92dd22fba60a421bde48258 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ermal=20Lu=C3=A7i?= Date: Sun, 30 Nov 2008 20:46:27 +0000 Subject: * Fix the actions on these page. Now renew/release/connect/disconnect work propperly. * Make the page redirect to itself instead of index.php since we might not have permission on the later. --- usr/local/www/status_interfaces.php | 64 ++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 29 deletions(-) (limited to 'usr/local/www') diff --git a/usr/local/www/status_interfaces.php b/usr/local/www/status_interfaces.php index 20d01f9..74d2f31 100755 --- a/usr/local/www/status_interfaces.php +++ b/usr/local/www/status_interfaces.php @@ -42,14 +42,14 @@ require_once("guiconfig.inc"); -if ($_POST) { - $interface = $_POST['interface']; - if ($_POST['submit'] == "Disconnect" || $_POST['submit'] == "Release") { +if ($_GET['if']) { + $interface = $_GET['if']; + if ($_GET['action'] == "Disconnect" || $_GET['action'] == "Release") { interface_bring_down($interface); - } else if ($_POST['submit'] == "Connect" || $_POST['submit'] == "Renew") { + } else if ($_GET['action'] == "Connect" || $_GET['action'] == "Renew") { interface_configure($interface); } else { - header("Location: index.php"); + header("Location: status_interfaces.php"); exit; } } @@ -66,8 +66,6 @@ include("head.inc"); foreach ($ifdescrs as $ifdescr => $ifname): $ifinfo = get_interface_info($ifdescr); ?> -
- @@ -86,37 +84,46 @@ include("head.inc"); - - DHCP - -    - - - - - - - + + DHCP + +    + + + + + + + + + + PPPoE    - - - - - + + + + + + + + PPTP    - - - - - + + + + + + + + @@ -125,7 +132,6 @@ include("head.inc"); -
-- cgit v1.1