summaryrefslogtreecommitdiffstats
path: root/usr/local/www/services_captiveportal_ip.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-09-13 18:34:39 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-09-13 18:34:39 +0000
commitc980716edb28b33e6340f00ab37ab36f5b860950 (patch)
treef9acce404a5c8e881302c67d93807fffb04102e3 /usr/local/www/services_captiveportal_ip.php
parent1d2043b89454eafa2e9836a2e7fa84dde0296208 (diff)
downloadpfsense-c980716edb28b33e6340f00ab37ab36f5b860950.zip
pfsense-c980716edb28b33e6340f00ab37ab36f5b860950.tar.gz
Sync with m0n0wall 1.2b10:
TODO: * Add back sexy curved tabs, etc * Change image locations to themes * Add back pfSense header information and set page titles
Diffstat (limited to 'usr/local/www/services_captiveportal_ip.php')
-rwxr-xr-xusr/local/www/services_captiveportal_ip.php84
1 files changed, 30 insertions, 54 deletions
diff --git a/usr/local/www/services_captiveportal_ip.php b/usr/local/www/services_captiveportal_ip.php
index 7ef988b..2266496 100755
--- a/usr/local/www/services_captiveportal_ip.php
+++ b/usr/local/www/services_captiveportal_ip.php
@@ -1,23 +1,22 @@
#!/usr/local/bin/php
<?php
-/* $Id$ */
/*
services_captiveportal_ip.php
part of m0n0wall (http://m0n0.ch/wall)
-
+
Copyright (C) 2004 Dinesh Nair <dinesh@alphaque.com>
All rights reserved.
-
+
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
-
+
1. Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
-
+
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
-
+
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
@@ -30,6 +29,7 @@
POSSIBILITY OF SUCH DAMAGE.
*/
+$pgtitle = array("Services", "Captive portal");
require("guiconfig.inc");
if (!is_array($config['captiveportal']['allowedip']))
@@ -67,35 +67,26 @@ if ($_GET['act'] == "del") {
exit;
}
}
-
-$pgtitle = "Services: Captive Portal: Allowed IP's";
-include("head.inc");
-
?>
-
-<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
<?php include("fbegin.inc"); ?>
-<p class="pgtitle"><?=$pgtitle?></p>
<form action="services_captiveportal_ip.php" method="post">
<?php if ($savemsg) print_info_box($savemsg); ?>
<?php if (file_exists($d_allowedipsdirty_path)): ?><p>
<?php print_info_box_np("The captive portal IP address configuration has been changed.<br>You must apply the changes in order for them to take effect.");?><br>
+<input name="apply" type="submit" class="formbtn" id="apply" value="Apply changes"></p>
<?php endif; ?>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr><td class="tabnavtbl">
-<?php
- $tab_array = array();
- $tab_array[0] = array("Captive portal", false, "services_captiveportal.php");
- $tab_array[1] = array("Pass-through MAC", false, "services_captiveportal_mac.php");
- $tab_array[2] = array("Allowed IP addresses", true, "services_captiveportal_ip.php");
- $tab_array[3] = array("Users", false, "services_captiveportal_users.php");
- display_top_tabs($tab_array);
-?>
+ <ul id="tabnav">
+ <li class="tabinact1"><a href="services_captiveportal.php">Captive portal</a></li>
+ <li class="tabinact"><a href="services_captiveportal_mac.php">Pass-through MAC</a></li>
+ <li class="tabact">Allowed IP addresses</li>
+ <li class="tabinact"><a href="services_captiveportal_users.php">Users</a></li>
+ </ul>
</td></tr>
<tr>
- <td>
-<div id="mainarea">
- <table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
+ <td class="tabcont">
+ <table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="30%" class="listhdrr">IP address</td>
<td width="60%" class="listhdr">Description</td>
@@ -103,37 +94,25 @@ include("head.inc");
</tr>
<?php $i = 0; foreach ($a_allowedips as $ip): ?>
<tr>
- <td class="listlr" ondblclick="document.location='services_captiveportal_ip_edit.php?id=<?=$i;?>';">
- <?php if($ip['dir'] == "to")
- echo "any <img src=\"./themes/".$g['theme']."/images/icons/icon_in.gif\" width=\"11\" height=\"11\" align=\"absmiddle\">";
- ?>
+ <td class="listlr">
+ <?php if($ip['dir'] == "to")
+ echo "any <img src=\"in.gif\" width=\"11\" height=\"11\" align=\"absmiddle\">";
+ ?>
<?=strtolower($ip['ip']);?>
- <?php if($ip['dir'] == "from")
- echo "<img src=\"./themes/".$g['theme']."/images/icons/icon_in.gif\" width=\"11\" height=\"11\" align=\"absmiddle\"> any";
- ?>
+ <?php if($ip['dir'] == "from")
+ echo "<img src=\"in.gif\" width=\"11\" height=\"11\" align=\"absmiddle\"> any";
+ ?>
</td>
- <td class="listbg" ondblclick="document.location='services_captiveportal_ip_edit.php?id=<?=$i;?>';">
- <font color="white"><?=htmlspecialchars($ip['descr']);?>&nbsp;</font>
+ <td class="listbg">
+ <?=htmlspecialchars($ip['descr']);?>&nbsp;
</td>
- <td valign="middle" nowrap class="list">
- <table border="0" cellspacing="0" cellpadding="1">
- <tr>
- <td valign="middle"><a href="services_captiveportal_ip_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a></td>
- <td valign="middle"><a href="services_captiveportal_ip.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this address?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
- </tr>
- </table>
- </td>
+ <td valign="middle" nowrap class="list"> <a href="services_captiveportal_ip_edit.php?id=<?=$i;?>"><img src="e.gif" title="edit address" width="17" height="17" border="0"></a>
+ &nbsp;<a href="services_captiveportal_ip.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this address?')"><img src="x.gif" title="delete address" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
- <tr>
+ <tr>
<td class="list" colspan="2">&nbsp;</td>
- <td class="list">
- <table border="0" cellspacing="0" cellpadding="1">
- <tr>
- <td valign="middle"><a href="services_captiveportal_ip_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td>
- </td>
- </table>
- </td>
+ <td class="list"> <a href="services_captiveportal_ip_edit.php"><img src="plus.gif" title="add address" width="17" height="17" border="0"></a></td>
</tr>
<tr>
<td colspan="2" class="list"><p class="vexpl"><span class="red"><strong>
@@ -142,25 +121,22 @@ include("head.inc");
Adding allowed IP addresses will allow IP access to/from these addresses through the captive portal without being taken to the portal page. This can be used for a web server serving images for the portal page or a DNS server on another network, for example. By specifying <em>from</em> addresses, it may be used to always allow pass-through access from a client behind the captive portal.</p>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
- <td><span class="vexpl">any <img src="./themes/<?= $g['theme']; ?>/images/icons/icon_in.gif" width="11" height="11" align="absmiddle"> x.x.x.x </span></td>
+ <td><span class="vexpl">any <img src="in.gif" width="11" height="11" align="absmiddle"> x.x.x.x </span></td>
<td><span class="vexpl">All connections <strong>to</strong> the IP address are allowed</span></td>
</tr>
<tr>
<td colspan="5" height="4"></td>
</tr>
<tr>
- <td>x.x.x.x <span class="vexpl"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_in.gif" width="11" height="11" align="absmiddle"></span> any&nbsp;&nbsp;&nbsp; </td>
+ <td>x.x.x.x <span class="vexpl"><img src="in.gif" width="11" height="11" align="absmiddle"></span> any&nbsp;&nbsp;&nbsp; </td>
<td><span class="vexpl">All connections <strong>from</strong> the IP address are allowed </span></td>
</tr>
</table></td>
<td class="list">&nbsp;</td>
</tr>
</table>
-</div>
</td>
</tr>
</table>
</form>
<?php include("fend.inc"); ?>
-</body>
-</html>
OpenPOWER on IntegriCloud