summaryrefslogtreecommitdiffstats
path: root/usr/local/www/diag_ping.php
diff options
context:
space:
mode:
authorsullrich <sullrich@pfsense.org>2009-12-05 21:47:56 -0500
committersullrich <sullrich@pfsense.org>2009-12-05 21:47:56 -0500
commitb8cc74edfbf22799fa359a3c904eb8672609e392 (patch)
tree0ec862ebbe29dabe2ac3908863d8a30453f8f28a /usr/local/www/diag_ping.php
parent91a73b8acfbb5fac4735dd4830a5c6e0198253ea (diff)
downloadpfsense-b8cc74edfbf22799fa359a3c904eb8672609e392.zip
pfsense-b8cc74edfbf22799fa359a3c904eb8672609e392.tar.gz
Allow GET calling of diag_ping and diag_traceroute so other areas of the GUI can easily link to them. Add links from DNS page for ping and traceroute.
Diffstat (limited to 'usr/local/www/diag_ping.php')
-rwxr-xr-xusr/local/www/diag_ping.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/usr/local/www/diag_ping.php b/usr/local/www/diag_ping.php
index 0ce85e3..4d82e06 100755
--- a/usr/local/www/diag_ping.php
+++ b/usr/local/www/diag_ping.php
@@ -46,24 +46,24 @@ require("guiconfig.inc");
define('MAX_COUNT', 10);
define('DEFAULT_COUNT', 3);
-if ($_POST) {
+if ($_POST || $_REQUEST['host']) {
unset($input_errors);
unset($do_ping);
/* input validation */
$reqdfields = explode(" ", "host count");
$reqdfieldsn = explode(",", "Host,Count");
- do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
+ do_input_validation($_REQUEST, $reqdfields, $reqdfieldsn, &$input_errors);
- if (($_POST['count'] < 1) || ($_POST['count'] > MAX_COUNT)) {
+ if (($_REQUEST['count'] < 1) || ($_REQUEST['count'] > MAX_COUNT)) {
$input_errors[] = "Count must be between 1 and {MAX_COUNT}";
}
if (!$input_errors) {
$do_ping = true;
- $host = $_POST['host'];
- $interface = $_POST['interface'];
- $count = $_POST['count'];
+ $host = $_REQUEST['host'];
+ $interface = $_REQUEST['interface'];
+ $count = $_REQUEST['count'];
}
}
if (!isset($do_ping)) {
@@ -145,3 +145,4 @@ include("head.inc"); ?>
</tr>
</table>
<?php include("fend.inc"); ?>
+
OpenPOWER on IntegriCloud