summaryrefslogtreecommitdiffstats
path: root/src/usr
diff options
context:
space:
mode:
authorPhil Davis <phil.davis@inf.org>2015-11-08 21:25:14 +0545
committerPhil Davis <phil.davis@inf.org>2015-11-08 21:25:14 +0545
commit0d97632543e3e98ac165025db75d10c1e678f178 (patch)
treea371595d7dd1d8f3257e5b034fea1cff54a48f7b /src/usr
parenta6e44b82f4584cdb656dc9c42eab1a88f19cc3c1 (diff)
downloadpfsense-0d97632543e3e98ac165025db75d10c1e678f178.zip
pfsense-0d97632543e3e98ac165025db75d10c1e678f178.tar.gz
Captive Portal code review
Make the capitalisation of the various heading pages consistent. Fix various field var name errors observed.
Diffstat (limited to 'src/usr')
-rw-r--r--src/usr/local/www/services_captiveportal.php42
-rw-r--r--src/usr/local/www/services_captiveportal_filemanager.php6
-rw-r--r--src/usr/local/www/services_captiveportal_hostname.php7
-rw-r--r--src/usr/local/www/services_captiveportal_hostname_edit.php7
-rw-r--r--src/usr/local/www/services_captiveportal_ip.php4
-rw-r--r--src/usr/local/www/services_captiveportal_ip_edit.php2
-rw-r--r--src/usr/local/www/services_captiveportal_mac.php6
-rw-r--r--src/usr/local/www/services_captiveportal_mac_edit.php2
-rw-r--r--src/usr/local/www/services_captiveportal_vouchers.php8
-rw-r--r--src/usr/local/www/services_captiveportal_vouchers_edit.php2
-rw-r--r--src/usr/local/www/services_captiveportal_zones.php4
-rw-r--r--src/usr/local/www/services_captiveportal_zones_edit.php2
12 files changed, 49 insertions, 43 deletions
diff --git a/src/usr/local/www/services_captiveportal.php b/src/usr/local/www/services_captiveportal.php
index 27ff6fe..4b5cc64 100644
--- a/src/usr/local/www/services_captiveportal.php
+++ b/src/usr/local/www/services_captiveportal.php
@@ -96,7 +96,7 @@ if (!is_array($config['captiveportal'])) {
}
$a_cp =& $config['captiveportal'];
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), $a_cp[$cpzone]['zone']);
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), $a_cp[$cpzone]['zone']);
$shortcut_section = "captiveportal";
if ($_GET['act'] == "viewhtml") {
@@ -301,7 +301,7 @@ if ($_POST) {
}
if ($_POST['timeout'] > $deftime) {
- $input_errors[] = gettext("Hard timeout must be less or equal Default lease time set on DHCP Server");
+ $input_errors[] = gettext("Hard timeout must be less than or equal to the Default lease time set on DHCP Server");
}
}
}
@@ -558,9 +558,9 @@ if ($savemsg)
print_info_box($savemsg, 'success');
$tab_array = array();
-$tab_array[] = array(gettext("Captive portal(s)"), true, "services_captiveportal.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Captive Portal(s)"), true, "services_captiveportal.php?zone={$cpzone}");
$tab_array[] = array(gettext("MAC"), false, "services_captiveportal_mac.php?zone={$cpzone}");
-$tab_array[] = array(gettext("Allowed IP addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Allowed IP Addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed Hostnames"), false, "services_captiveportal_hostname.php?zone={$cpzone}");
$tab_array[] = array(gettext("Vouchers"), false, "services_captiveportal_vouchers.php?zone={$cpzone}");
$tab_array[] = array(gettext("File Manager"), false, "services_captiveportal_filemanager.php?zone={$cpzone}");
@@ -785,7 +785,7 @@ $group->add(new Form_Checkbox(
null,
'MSCHAPv2',
$pconfig['radius_protocol'] == 'MSCHAPv2',
- 'SCHAPv2'
+ 'MSCHAPv2'
))->displayasRadio();
$section->add($group);
@@ -835,10 +835,10 @@ $group->add(new Form_Input(
))->setHelp('RADIUS port. Leave blank for default (1812)');
$group->add(new Form_Input(
- 'radiuskey3',
+ 'radiuskey2',
null,
'text',
- $pconfig['radiuskey3']
+ $pconfig['radiuskey2']
))->setHelp('RADIUS shared secret. Leave blank to not use a shared secret (not recommended)');
$section->add($group);
@@ -851,23 +851,23 @@ $section->addClass('Secondary');
$group = new Form_Group('Primary RADIUS server');
$group->add(new Form_IpAddress(
- 'radiusip4',
+ 'radiusip3',
null,
- $pconfig['radiusip4']
+ $pconfig['radiusip3']
));
$group->add(new Form_Input(
- 'radiusport4',
+ 'radiusport3',
null,
'number',
- $pconfig['radiusport4']
+ $pconfig['radiusport3']
));
$group->add(new Form_Input(
- 'radiuskey4',
+ 'radiuskey3',
null,
'text',
- $pconfig['radiuskey4']
+ $pconfig['radiuskey3']
));
$section->add($group);
@@ -875,23 +875,23 @@ $section->add($group);
$group = new Form_Group('Secondary RADIUS server');
$group->add(new Form_IpAddress(
- 'radiusip',
+ 'radiusip4',
null,
- $pconfig['radiusip']
+ $pconfig['radiusip4']
))->setHelp('IP address of the RADIUS server to authenticate against.');
$group->add(new Form_Input(
- 'radiusport',
+ 'radiusport4',
null,
'number',
- $pconfig['radiusport']
+ $pconfig['radiusport4']
))->setHelp('RADIUS port. Leave blank for default (1812)');
$group->add(new Form_Input(
- 'radiuskey',
+ 'radiuskey4',
null,
'text',
- $pconfig['radiuskey']
+ $pconfig['radiuskey4']
))->setHelp('RADIUS shared secret. Leave blank to not use a shared secret (not recommended)');
$section->add($group);
@@ -926,7 +926,7 @@ $group->add(new Form_Checkbox(
$group->add(new Form_Checkbox(
'reauthenticateacct',
null,
- 'Stop/stop Accounting',
+ 'Stop/start Accounting',
$pconfig['reauthenticateacct'] == 'stopstart'
))->displayasRadio();
@@ -1042,7 +1042,7 @@ $section->addInput(new Form_Input(
$section->addInput(new Form_Select(
'certref',
- 'SSL Certigicate',
+ 'SSL Certificate',
$pconfig['certref'],
build_cert_list()
))->setHelp('If no certificates are defined, you may define one here: ' . '<a href="system_certmanager.php">System &gt; Cert Manager</a>');
diff --git a/src/usr/local/www/services_captiveportal_filemanager.php b/src/usr/local/www/services_captiveportal_filemanager.php
index c4d67ac..34be0fe 100644
--- a/src/usr/local/www/services_captiveportal_filemanager.php
+++ b/src/usr/local/www/services_captiveportal_filemanager.php
@@ -99,7 +99,7 @@ if (!is_array($config['captiveportal'])) {
}
$a_cp =& $config['captiveportal'];
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), $a_cp[$cpzone]['zone']);
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), $a_cp[$cpzone]['zone']);
$shortcut_section = "captiveportal";
if (!is_array($a_cp[$cpzone]['element'])) {
@@ -171,9 +171,9 @@ if ($input_errors)
print_input_errors($input_errors);
$tab_array = array();
-$tab_array[] = array(gettext("Captive portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Captive Portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
$tab_array[] = array(gettext("MAC"), false, "services_captiveportal_mac.php?zone={$cpzone}");
-$tab_array[] = array(gettext("Allowed IP addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Allowed IP Addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed Hostnames"), false, "services_captiveportal_hostname.php?zone={$cpzone}");
$tab_array[] = array(gettext("Vouchers"), false, "services_captiveportal_vouchers.php?zone={$cpzone}");
$tab_array[] = array(gettext("File Manager"), true, "services_captiveportal_filemanager.php?zone={$cpzone}");
diff --git a/src/usr/local/www/services_captiveportal_hostname.php b/src/usr/local/www/services_captiveportal_hostname.php
index c5937c6..3d695fa 100644
--- a/src/usr/local/www/services_captiveportal_hostname.php
+++ b/src/usr/local/www/services_captiveportal_hostname.php
@@ -1,4 +1,7 @@
<?php
+/*
+ services_captiveportal_hostname.php
+*/
/* ====================================================================
* Copyright (c) 2004-2015 Electric Sheep Fencing, LLC. All rights reserved.
*
@@ -93,7 +96,7 @@ if (isset($cpzone) && !empty($cpzone) && isset($a_cp[$cpzone]['zoneid'])) {
$cpzoneid = $a_cp[$cpzone]['zoneid'];
}
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), $a_cp[$cpzone]['zone']);
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), $a_cp[$cpzone]['zone']);
$shortcut_section = "captiveportal";
if ($_GET['act'] == "del" && !empty($cpzone) && isset($cpzoneid)) {
@@ -135,7 +138,7 @@ if ($savemsg)
print_info_box($savemsg);
$tab_array = array();
-$tab_array[] = array(gettext("Captive portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Captive Portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
$tab_array[] = array(gettext("MAC"), false, "services_captiveportal_mac.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed IP Addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed Hostnames"), true, "services_captiveportal_hostname.php?zone={$cpzone}");
diff --git a/src/usr/local/www/services_captiveportal_hostname_edit.php b/src/usr/local/www/services_captiveportal_hostname_edit.php
index de7ad03..739b46e 100644
--- a/src/usr/local/www/services_captiveportal_hostname_edit.php
+++ b/src/usr/local/www/services_captiveportal_hostname_edit.php
@@ -1,4 +1,7 @@
<?php
+/*
+ services_captiveportal_hostname_edit.php
+*/
/* ====================================================================
* Copyright (c) 2004-2015 Electric Sheep Fencing, LLC. All rights reserved.
*
@@ -78,7 +81,7 @@ require("captiveportal.inc");
global $cpzone, $cpzoneid;
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), gettext("Edit allowed Hostname"));
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), gettext("Edit allowed Hostname"));
$shortcut_section = "captiveportal";
$cpzone = $_GET['zone'];
@@ -213,7 +216,7 @@ $section->addInput(new Form_Select(
'Direction',
strtolower($pconfig['dir']),
build_dir_list()
-))->setHelp('Use "From" to always allow an Hostname through the captive portal (without authentication). ' .
+))->setHelp('Use "From" to always allow a Hostname through the captive portal (without authentication). ' .
'Use "To" to allow access from all clients (even non-authenticated ones) behind the portal to this Hostname.');
$section->addInput(new Form_Input(
diff --git a/src/usr/local/www/services_captiveportal_ip.php b/src/usr/local/www/services_captiveportal_ip.php
index 37da965..2754375 100644
--- a/src/usr/local/www/services_captiveportal_ip.php
+++ b/src/usr/local/www/services_captiveportal_ip.php
@@ -95,7 +95,7 @@ if (isset($cpzone) && !empty($cpzone) && isset($a_cp[$cpzone]['zoneid'])) {
$cpzoneid = $a_cp[$cpzone]['zoneid'];
}
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), $a_cp[$cpzone]['zone']);
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), $a_cp[$cpzone]['zone']);
$shortcut_section = "captiveportal";
if ($_GET['act'] == "del" && !empty($cpzone) && isset($cpzoneid)) {
@@ -131,7 +131,7 @@ if ($savemsg)
print_info_box($savemsg);
$tab_array = array();
-$tab_array[] = array(gettext("Captive portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Captive Portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
$tab_array[] = array(gettext("MAC"), false, "services_captiveportal_mac.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed IP Addresses"), true, "services_captiveportal_ip.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed Hostnames"), false, "services_captiveportal_hostname.php?zone={$cpzone}");
diff --git a/src/usr/local/www/services_captiveportal_ip_edit.php b/src/usr/local/www/services_captiveportal_ip_edit.php
index 88f0a52..1ee804b 100644
--- a/src/usr/local/www/services_captiveportal_ip_edit.php
+++ b/src/usr/local/www/services_captiveportal_ip_edit.php
@@ -84,7 +84,7 @@ require_once("filter.inc");
require("shaper.inc");
require("captiveportal.inc");
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), gettext("Edit allowed IP address"));
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), gettext("Edit allowed IP address"));
$shortcut_section = "captiveportal";
$cpzone = $_GET['zone'];
diff --git a/src/usr/local/www/services_captiveportal_mac.php b/src/usr/local/www/services_captiveportal_mac.php
index e45da34..9c81f2d 100644
--- a/src/usr/local/www/services_captiveportal_mac.php
+++ b/src/usr/local/www/services_captiveportal_mac.php
@@ -90,7 +90,7 @@ if (!is_array($config['captiveportal'])) {
}
$a_cp =& $config['captiveportal'];
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), $a_cp[$cpzone]['zone']);
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), $a_cp[$cpzone]['zone']);
$shortcut_section = "captiveportal";
$actsmbl = array('pass' => '<font color="green" size="4">&#x2714;</font>&nbsp;Pass',
@@ -193,9 +193,9 @@ if (is_subsystem_dirty('passthrumac'))
print_info_box_np(gettext("The captive portal MAC address configuration has been changed.<br />You must apply the changes in order for them to take effect."));
$tab_array = array();
-$tab_array[] = array(gettext("Captive portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Captive Portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
$tab_array[] = array(gettext("MAC"), true, "services_captiveportal_mac.php?zone={$cpzone}");
-$tab_array[] = array(gettext("Allowed IP addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Allowed IP Addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed Hostnames"), false, "services_captiveportal_hostname.php?zone={$cpzone}");
$tab_array[] = array(gettext("Vouchers"), false, "services_captiveportal_vouchers.php?zone={$cpzone}");
$tab_array[] = array(gettext("File Manager"), false, "services_captiveportal_filemanager.php?zone={$cpzone}");
diff --git a/src/usr/local/www/services_captiveportal_mac_edit.php b/src/usr/local/www/services_captiveportal_mac_edit.php
index 3750b42..5de3e66 100644
--- a/src/usr/local/www/services_captiveportal_mac_edit.php
+++ b/src/usr/local/www/services_captiveportal_mac_edit.php
@@ -86,7 +86,7 @@ require("captiveportal.inc");
global $cpzone;
global $cpzoneid;
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), gettext("Edit MAC address rules"));
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), gettext("Edit MAC address rules"));
$shortcut_section = "captiveportal";
$cpzone = $_GET['zone'];
diff --git a/src/usr/local/www/services_captiveportal_vouchers.php b/src/usr/local/www/services_captiveportal_vouchers.php
index e2a36c9..84e0e72 100644
--- a/src/usr/local/www/services_captiveportal_vouchers.php
+++ b/src/usr/local/www/services_captiveportal_vouchers.php
@@ -111,7 +111,7 @@ if (empty($a_cp[$cpzone])) {
exit;
}
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), gettext("Vouchers"), $a_cp[$cpzone]['zone']);
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), gettext("Vouchers"), $a_cp[$cpzone]['zone']);
$shortcut_section = "captiveportal-vouchers";
if (!is_array($config['voucher'][$cpzone]['roll'])) {
@@ -430,9 +430,9 @@ if ($savemsg)
print_info_box($savemsg. 'success');
$tab_array = array();
-$tab_array[] = array(gettext("Captive portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Captive Portal(s)"), false, "services_captiveportal.php?zone={$cpzone}");
$tab_array[] = array(gettext("MAC"), false, "services_captiveportal_mac.php?zone={$cpzone}");
-$tab_array[] = array(gettext("Allowed IP addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
+$tab_array[] = array(gettext("Allowed IP Addresses"), false, "services_captiveportal_ip.php?zone={$cpzone}");
$tab_array[] = array(gettext("Allowed Hostnames"), false, "services_captiveportal_hostname.php?zone={$cpzone}");
$tab_array[] = array(gettext("Vouchers"), true, "services_captiveportal_vouchers.php?zone={$cpzone}");
$tab_array[] = array(gettext("File Manager"), false, "services_captiveportal_filemanager.php?zone={$cpzone}");
@@ -613,7 +613,7 @@ $section->addInput(new Form_Input(
'vouchersyncpass',
'Voucher sync password',
'password',
- $pconfig['vouchersyncuserpass']
+ $pconfig['vouchersyncpass']
))->setHelp('This is the password of the master voucher nodes webConfigurator.');
$section->addInput(new Form_Input(
diff --git a/src/usr/local/www/services_captiveportal_vouchers_edit.php b/src/usr/local/www/services_captiveportal_vouchers_edit.php
index 2ee9d43..f58cdc2 100644
--- a/src/usr/local/www/services_captiveportal_vouchers_edit.php
+++ b/src/usr/local/www/services_captiveportal_vouchers_edit.php
@@ -71,7 +71,7 @@ require("shaper.inc");
require("captiveportal.inc");
require_once("voucher.inc");
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), gettext("Edit Voucher Rolls"));
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), gettext("Edit Voucher Rolls"));
$shortcut_section = "captiveportal-vouchers";
$cpzone = $_GET['zone'];
diff --git a/src/usr/local/www/services_captiveportal_zones.php b/src/usr/local/www/services_captiveportal_zones.php
index 62b8583..338bb41 100644
--- a/src/usr/local/www/services_captiveportal_zones.php
+++ b/src/usr/local/www/services_captiveportal_zones.php
@@ -98,11 +98,11 @@ if ($savemsg)
print_info_box($savemsg, success);
if (is_subsystem_dirty('captiveportal'))
- print_info_box_np(gettext("The CaptivePortal entry list has been changed") . ".<br />" . gettext("You must apply the changes in order for them to take effect."));
+ print_info_box_np(gettext("The Captive Portal entry list has been changed") . ".<br />" . gettext("You must apply the changes in order for them to take effect."));
?>
<form action="services_captiveportal_zones.php" method="post">
<div class="panel panel-default">
- <div class="panel-heading"><h2 class="panel-title"><?=gettext('Captive portal Zones')?></h2></div>
+ <div class="panel-heading"><h2 class="panel-title"><?=gettext('Captive Portal Zones')?></h2></div>
<div class="panel-body table-responsive">
<table class="table table-striped table-hover">
<thead>
diff --git a/src/usr/local/www/services_captiveportal_zones_edit.php b/src/usr/local/www/services_captiveportal_zones_edit.php
index 6804525..275af01 100644
--- a/src/usr/local/www/services_captiveportal_zones_edit.php
+++ b/src/usr/local/www/services_captiveportal_zones_edit.php
@@ -69,7 +69,7 @@ require_once("filter.inc");
require("shaper.inc");
require("captiveportal.inc");
-$pgtitle = array(gettext("Services"), gettext("Captive portal"), gettext("Edit Zones"));
+$pgtitle = array(gettext("Services"), gettext("Captive Portal"), gettext("Edit Zones"));
$shortcut_section = "captiveportal";
if (!is_array($config['captiveportal'])) {
OpenPOWER on IntegriCloud