Revision: 6371
http://ipcop.svn.sourceforge.net/ipcop/?rev=6371&view=rev
Author: owes
Date: 2012-02-18 22:40:03 +0000 (Sat, 18 Feb 2012)
Log Message:
-----------
First block of URL filter text simplifications and html validator fixes.
Modified Paths:
--------------
ipcop/trunk/html/cgi-bin/urlfilter.cgi
Modified: ipcop/trunk/html/cgi-bin/urlfilter.cgi
===================================================================
--- ipcop/trunk/html/cgi-bin/urlfilter.cgi 2012-02-18 22:04:38 UTC (rev
6370)
+++ ipcop/trunk/html/cgi-bin/urlfilter.cgi 2012-02-18 22:40:03 UTC (rev
6371)
@@ -1222,7 +1222,7 @@
print "<form method='post' action='$ENV{'SCRIPT_NAME'}'
enctype='multipart/form-data'>\n";
- &Header::openbox('100%', 'left', "$Lang::tr{'urlfilter filter
settings'}:");
+ &Header::openbox('100%', 'left', "$Lang::tr{'settings'}:");
print <<END
<table width='100%'>
<tr>
@@ -1235,10 +1235,10 @@
<td width='25%'> </td>
</tr>
</table>
-<hr size='1'>
+<hr size='1' />
<table width='100%'>
<tr>
- <td colspan='4'><b>$Lang::tr{'urlfilter block categories'}</b></td>
+ <td colspan='4'><b>$Lang::tr{'block categories'}</b></td>
</tr>
END
;
@@ -1246,7 +1246,7 @@
if (@categories == 0) {
print <<END
<tr>
- <td width='25%'><i>$Lang::tr{'urlfilter no categories'}</i></td>
+ <td width='25%'><i>$Lang::tr{'no categories'}</i></td>
<td width='25%'> </td>
<td width='25%'> </td>
<td width='25%'> </td>
@@ -1255,44 +1255,50 @@
END
;
}
-
- for ($n = 0; $n <= @categories; $n = $n + $i) {
- for ($i = 0; $i <= 3; $i++) {
- if ($i eq 0) {
- print "<tr>\n";
- }
- if (($n + $i) < @categories) {
- my $name = $categories[$n+$i];
- my $category = $filtergroups[$n+$i];
- my $checked = '';
- if(defined($filtersettings{$category}) &&
$filtersettings{$category} eq 'on') {
- $checked = "checked='checked'";
+ else {
+ for ($n = 0; $n <= @categories; $n = $n + $i) {
+ for ($i = 0; $i <= 3; $i++) {
+ if ($i eq 0) {
+ print "<tr>\n";
}
- print "<td width='15%'>$name:<\/td>\n";
- print "<td width='10%'><input type='checkbox'
name='$category' $checked /></td>\n";
+ if (($n + $i) < @categories) {
+ my $name = $categories[$n+$i];
+ my $category = $filtergroups[$n+$i];
+ my $checked = '';
+ if(defined($filtersettings{$category}) &&
$filtersettings{$category} eq 'on') {
+ $checked = "checked='checked'";
+ }
+ print "<td width='15%'>$name:<\/td>\n";
+ print "<td width='10%'><input type='checkbox'
name='$category' $checked /></td>\n";
+ }
+ if ($i eq 3) {
+ print "<\/tr>\n";
+ }
}
- if ($i eq 3) {
- print "<\/tr>\n";
- }
}
}
-
print <<END
</table>
-<hr size='1'>
+<hr size='1' />
<table width='100%'>
<tr>
- <td width='25%'><b>$Lang::tr{'urlfilter custom blacklist'}</b></td>
- <td width='25%'> </td>
- <td width='25%'> </td>
- <td width='25%'> </td>
+ <td width='25%'><b>$Lang::tr{'custom blacklist'}</b></td>
+ <td width='25%'> </td>
+ <td width='25%'> </td>
+ <td width='25%'> </td>
</tr>
<tr>
- <td colspan='2'>$Lang::tr{'urlfilter blocked domains'} <img
src='/blob.gif' alt='*' /></td>
- <td colspan='2'>$Lang::tr{'urlfilter blocked urls'} <img
src='/blob.gif' alt='*' /></td>
+ <td width='25%' class='base'>$Lang::tr{'enabled'}:</td>
+ <td width='25%'><input type='checkbox' name='ENABLE_CUSTOM_BLACKLIST'
$checked{'ENABLE_CUSTOM_BLACKLIST'}{'on'} /></td>
+ <td width='25%'> </td>
+ <td width='25%'> </td>
</tr>
<tr>
- <td colspan='2'><textarea name='CUSTOM_BLACK_DOMAINS' cols='32'
rows='6' wrap='off'>
+ <td colspan='2'>$Lang::tr{'blocked domains'} <img src='/blob.gif'
alt='*' /></td>
+ <td colspan='2'>$Lang::tr{'blocked urls'} <img src='/blob.gif'
alt='*' /></td>
+</tr>
+<tr>
+ <td colspan='2'><textarea name='CUSTOM_BLACK_DOMAINS' cols='32' rows='6'
wrap='off'>
END
;
@@ -1302,7 +1308,7 @@
print <<END
</textarea></td>
- <td colspan='2'><textarea name='CUSTOM_BLACK_URLS' cols='32' rows='6'
wrap='off'>
+ <td colspan='2'><textarea name='CUSTOM_BLACK_URLS' cols='32' rows='6'
wrap='off'>
END
;
@@ -1314,28 +1320,26 @@
</textarea></td>
</tr>
</table>
+<hr size='1' />
<table width='100%'>
<tr>
- <td width='25%' class='base'>$Lang::tr{'urlfilter enable custom
blacklist'}:</td>
- <td width='25%'><input type='checkbox' name='ENABLE_CUSTOM_BLACKLIST'
$checked{'ENABLE_CUSTOM_BLACKLIST'}{'on'} /></td>
- <td width='25%'> </td>
- <td width='25%'> </td>
+ <td><b>$Lang::tr{'custom whitelist'}</b></td>
+ <td> </td>
+ <td> </td>
+ <td> </td>
</tr>
-</table>
-<hr size='1'>
-<table width='100%'>
<tr>
- <td><b>$Lang::tr{'urlfilter custom whitelist'}</b></td>
- <td> </td>
- <td> </td>
- <td> </td>
+ <td class='base' width='25%'>$Lang::tr{'enabled'}:</td>
+ <td width='25%'><input type='checkbox' name='ENABLE_CUSTOM_WHITELIST'
$checked{'ENABLE_CUSTOM_WHITELIST'}{'on'} /></td>
+ <td width='25%'> </td>
+ <td width='25%'> </td>
</tr>
<tr>
- <td colspan='2'>$Lang::tr{'urlfilter allowed domains'} <img
src='/blob.gif' alt='*' /></td>
- <td colspan='2'>$Lang::tr{'urlfilter allowed urls'} <img
src='/blob.gif' alt='*' /></td>
+ <td colspan='2'>$Lang::tr{'allowed domains'} <img src='/blob.gif'
alt='*' /></td>
+ <td colspan='2'>$Lang::tr{'allowed urls'} <img src='/blob.gif'
alt='*' /></td>
</tr>
<tr>
- <td colspan='2'><textarea name='CUSTOM_WHITE_DOMAINS' cols='32'
rows='6' wrap='off'>
+ <td colspan='2'><textarea name='CUSTOM_WHITE_DOMAINS' cols='32' rows='6'
wrap='off'>
END
;
@@ -1345,7 +1349,7 @@
print <<END
</textarea></td>
- <td colspan='2'><textarea name='CUSTOM_WHITE_URLS' cols='32' rows='6'
wrap='off'>
+ <td colspan='2'><textarea name='CUSTOM_WHITE_URLS' cols='32' rows='6'
wrap='off'>
END
;
@@ -1357,24 +1361,22 @@
</textarea></td>
</tr>
</table>
+<hr size='1' />
<table width='100%'>
<tr>
- <td class='base' width='25%'>$Lang::tr{'urlfilter enable custom
whitelist'}:</td>
- <td width='25%'><input type='checkbox' name='ENABLE_CUSTOM_WHITELIST'
$checked{'ENABLE_CUSTOM_WHITELIST'}{'on'} /></td>
- <td width='25%'> </td>
- <td width='25%'> </td>
+ <td colspan='4'><b>$Lang::tr{'custom expression list'}</b></td>
+</tr><tr>
+ <td class='base' width='25%'>$Lang::tr{'enabled'}:</td>
+ <td width='25%'><input type='checkbox' name='ENABLE_CUSTOM_EXPRESSIONS'
$checked{'ENABLE_CUSTOM_EXPRESSIONS'}{'on'} /></td>
+ <td width='25%'> </td>
+ <td width='25%'> </td>
</tr>
-</table>
-<hr size='1'>
-<table width='100%'>
+
<tr>
- <td colspan='4'><b>$Lang::tr{'urlfilter custom expression
list'}</b></td>
+ <td colspan='4'>$Lang::tr{'blocked expressions'} <img src='/blob.gif'
alt='*' /></td>
</tr>
<tr>
- <td colspan='4'>$Lang::tr{'urlfilter blocked expressions'} <img
src='/blob.gif' alt='*' /></td>
-</tr>
-<tr>
- <td colspan='4'><textarea name='CUSTOM_EXPRESSIONS' cols='70' rows='3'
wrap='off'>
+ <td colspan='4'><textarea name='CUSTOM_EXPRESSIONS' cols='70' rows='3'
wrap='off'>
END
;
@@ -1385,14 +1387,8 @@
print <<END
</textarea></td>
</tr>
-<tr>
- <td class='base' width='25%'>$Lang::tr{'urlfilter enable custom
expression list'}:</td>
- <td width='25%'><input type='checkbox'
name='ENABLE_CUSTOM_EXPRESSIONS' $checked{'ENABLE_CUSTOM_EXPRESSIONS'}{'on'}
/></td>
- <td width='25%'> </td>
- <td width='25%'> </td>
-</tr>
</table>
-<hr size='1'>
+<hr size='1' />
<table width='100%'>
<tr>
<td colspan='4'><b>$Lang::tr{'urlfilter file ext block'}</b></td>
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Ipcop-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ipcop-svn