src: apply global whitespace cleanups

This commit is contained in:
Franco Fichtner 2015-01-02 12:11:43 +01:00
parent 46bf6e98a4
commit b20834ac48
21 changed files with 40 additions and 41 deletions

View File

@ -287,9 +287,9 @@ function get_default_captive_portal_html() {
global $config, $g, $cpzone;
$htmltext = <<<EOD
<html>
<body>
<form method="post" action="\$PORTAL_ACTION\$">
<html>
<body>
<form method="post" action="\$PORTAL_ACTION\$">
<input name="redirurl" type="hidden" value="\$PORTAL_REDIRURL\$">
<input name="zone" type="hidden" value="\$PORTAL_ZONE\$">
<center>
@ -370,7 +370,7 @@ EOD;
</table>
</center>
</form>
</body>
</body>
</html>
EOD;
@ -681,7 +681,7 @@ function captiveportal_init_webgui_zone($cpcfg) {
}
/*
/*
* Remove clients that have been around for longer than the specified amount of time
* db file structure:
* timestamp,ipfw_rule_no,clientip,clientmac,username,sessionid,password,session_timeout,idle_timeout,session_terminate_time,interim_interval
@ -703,7 +703,7 @@ function captiveportal_prune_old() {
}else{
// cleanup sessions if radius accounting is enable
// TODO: this code needs a rewrite, probably the easiest thing todo is update the zone administration and run
// the normal cleanup (portal_cleanup_sessions) to detach both processes
// the normal cleanup (portal_cleanup_sessions) to detach both processes
//
$vcpcfg = $config['voucher'][$cpzone];

View File

@ -1,6 +1,6 @@
<?php
/*
Copyritgh (C) 2014 Deciso B.V.
Copyritgh (C) 2014 Deciso B.V.
Copyright (C) Scott Ullrich
Copyright (C) 2009 Jim Pingle <myfirstname>@<mylastname>.org
All rights reserved.

View File

@ -109,4 +109,4 @@ class ARP
}
}
}

View File

@ -384,4 +384,4 @@ class DB {
}
}

View File

@ -327,4 +327,4 @@ class Rules {
file_put_contents($filename,$ruleset_txt);
}
}
}

View File

@ -123,4 +123,4 @@ class Shell
}
}
}

View File

@ -1,5 +1,5 @@
<?php
/*
/*
Copyritgh (C) 2014 Deciso B.V.
Copyright (C) 2010 - Jim Pingle
Copyright (C) 2006, Eric Friesen

View File

@ -1,5 +1,5 @@
<?php
/*
/*
Copyright (C) 2014 Deciso B.V.
Copyright (C) 2005 Paul Taylor (paultaylor@winndixie.com) and Manuel Kasper <mk@neon1.net>.
All rights reserved.

View File

@ -423,8 +423,8 @@ include("fbegin.inc");
<?php if (count($layer7_rules_list) > 0): ?>
<tr class="tabcont">
<td width="25%" align="left"></td><td width="75%"> </td>
</tr>
<td width="25%" align="left"></td><td width="75%"> </td>
</tr>
<?php endif; ?>
<tr>
@ -571,14 +571,14 @@ include("fbegin.inc");
<input id="delete" onclick="return confirm('Are you sure you want to delete?')" type="submit" class="btn btn-default formbtn" name="delete" value="<?=gettext("Delete"); ?>" />
</a>
<?php endif ?>
</td>
</tr>
<?php endif; ?>
<!-- End of layer7 rules form -->
</table>
</div><!-- end of div:shape area -->
</form>
</form>
</div>
</section>
</div>

View File

@ -1,6 +1,6 @@
<?php
/*
Copyright (C) 2014 Deciso B.V.
Copyright (C) 2014 Deciso B.V.
Copyright (C) 2004 Scott Ullrich
Copyright (C) 2003-2004 Manuel Kasper <mk@neon1.net>.
All rights reserved.

View File

@ -569,4 +569,3 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
</section>
<?php include("foot.inc"); ?>

View File

@ -50,10 +50,10 @@ $pgtitle = gettext("License");
<br />
<strong>
THIS SOFTWARE IS PROVIDED “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES,<br />
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.<br />
</strong><br />
OPNsense is based on <a href="http://www.freebsd.org" target="_blank">FreeBSD</a><br />

View File

@ -1,6 +1,6 @@
<?php
/*
Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2008 Bill Marquette <bill.marquette@gmail.com>.
All rights reserved.

View File

@ -562,7 +562,7 @@ function enable_change(enable_change) {
<?=gettext("minutes"); ?><br />
<?=gettext("Clients will be disconnected after this amount of time, regardless of activity. They may log in again immediately, though. Leave this field blank for no hard timeout (not recommended unless an idle timeout is set)."); ?></td>
</tr>
<!--
<!--
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Pass-through credits allowed per MAC address"); ?></td>
<td width="78%" class="vtable">
@ -584,7 +584,7 @@ function enable_change(enable_change) {
<strong><?=gettext("Enable waiting period reset on attempted access"); ?></strong><br />
<?=gettext("If enabled, the waiting period is reset to the original duration if access is attempted when all pass-through credits have already been exhausted."); ?></td>
</tr>
-->
-->
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Logout popup window"); ?></td>
<td width="78%" class="vtable">
@ -607,7 +607,7 @@ function enable_change(enable_change) {
<?=gettext("If you provide a URL here, clients will be redirected to that URL instead of the one they initially tried " .
"to access after they've authenticated."); ?></td>
</tr>
<!--
<!--
<tr>
<td valign="top" class="vncell"><?=gettext("Blocked MAC address redirect URL"); ?> </td>
<td class="vtable">
@ -615,7 +615,7 @@ function enable_change(enable_change) {
<?php printf(gettext("If you provide a URL here, MAC addresses set to be blocked will be redirect to that URL when attempt to access anything."));?>
</td>
</tr>
-->
-->
<tr>
<td valign="top" class="vncell"><?=gettext("Concurrent user logins"); ?></td>
<td class="vtable">
@ -623,7 +623,7 @@ function enable_change(enable_change) {
<strong><?=gettext("Disable concurrent logins"); ?></strong><br />
<?=gettext("If this option is set, only the most recent login per username will be active. Subsequent logins will cause machines previously logged in with the same username to be disconnected."); ?></td>
</tr>
<!--
<!--
<tr>
<td valign="top" class="vncell"><?=gettext("Per-user bandwidth restriction"); ?></td>
<td class="vtable">
@ -641,7 +641,7 @@ function enable_change(enable_change) {
<br />
<?=gettext("If this option is set, the captive portal will restrict each user who logs in to the specified default bandwidth. RADIUS can override the default settings. Leave empty or set to 0 for no limit."); ?> </td>
</tr>
-->
-->
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Authentication"); ?></td>
<td width="78%" class="vtable">

View File

@ -207,7 +207,7 @@ include("head.inc");
<br /> <span class="vexpl"><?=gettext("You may enter a description here for your reference (not parsed)"); ?>.</span>
</td>
</tr>
<!--
<!--
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Bandwidth up"); ?></td>
<td width="78%" class="vtable">
@ -222,7 +222,7 @@ include("head.inc");
<br /> <span class="vexpl"><?=gettext("Enter a download limit to be enforced on this IP address in Kbit/s"); ?></span>
</td>
</tr>
-->
-->
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">

View File

@ -224,7 +224,7 @@ include("head.inc");
<span class="vexpl"><?=gettext("You may enter a description here for your reference (not parsed)"); ?>.</span>
</td>
</tr>
<!--
<!--
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Bandwidth up"); ?></td>
<td width="78%" class="vtable">
@ -241,7 +241,7 @@ include("head.inc");
<span class="vexpl"><?=gettext("Enter a download limit to be enforced on this MAC address in Kbit/s"); ?></span>
</td>
</tr>
-->
-->
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">

View File

@ -171,7 +171,7 @@ include("head.inc");
?>
<body>
<script type="text/javascript">
//<![CDATA[
//Generic show an advanced option function

View File

@ -157,7 +157,7 @@ include("head.inc");
?>
<body>
<script type="text/javascript">
//<![CDATA[
function check_deps() {

View File

@ -161,7 +161,7 @@ include_once("head.inc");
?>
<body>
<script type="text/javascript">
//<![CDATA[
function enable_change(enable_over) {

View File

@ -68,7 +68,7 @@ function clientcmp($a, $b) {
if (!empty($cpzone)) {
$cpdb_handle = new OPNsense\CaptivePortal\DB($cpzone);
$cpclient_handle = new OPNsense\CaptivePortal\CPClient();
$cpclient_handle = new OPNsense\CaptivePortal\CPClient();
$order = "";
if ($_GET['order']) {
@ -79,7 +79,7 @@ if (!empty($cpzone)) {
$cpdb = $cpdb_handle->listClients(array(),"and",array($order) ) ;
if ($_GET['showact']) {
$accounting_info = $cpclient_handle->list_accounting();
$accounting_info = $cpclient_handle->list_accounting();
}
else {
$accounting_info = array() ;
@ -186,7 +186,7 @@ $mac_man = load_mac_manufacturer_table();
<td class="listr"><?=htmlspecialchars(date("m/d/Y H:i:s", $cpent->allow_time));?></td>
<?php if ($_GET['showact']):
//$last_act = captiveportal_get_last_activity($cpent->ip, $cpent->mac);
if ( array_key_exists($cpent->ip,$accounting_info) ) $last_act = $accounting_info[$cpent->ip]['last_accessed'] ;
if ( array_key_exists($cpent->ip,$accounting_info) ) $last_act = $accounting_info[$cpent->ip]['last_accessed'] ;
else $last_act=0;
?>
<td class="listr"><?php if ($last_act != 0) echo htmlspecialchars(date("m/d/Y H:i:s", $last_act));?></td>

View File

@ -2,7 +2,7 @@
/*
Copyright (C) 2014 Deciso B.V.
Copyright (C) 2008 Seth Mos
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met: