html cleanup
This commit is contained in:
parent
b9d77f6d39
commit
bbf4554d04
@ -243,7 +243,7 @@ foreach $k (sort { $a <=> $b } keys %$plist) {
|
||||
# (!$_[1]->{'gsname'} && !$found &&
|
||||
# $_[1]->{'gsdevice'} eq $type);
|
||||
local $got = $_[1]->{'ddesc'} eq $p->{'description'};
|
||||
printf "<option %s value='%s'>%s\n",
|
||||
printf "<option %s value='%s'>%s</option>\n",
|
||||
$got ? 'selected' : '',
|
||||
$p->{'description'}.";".join(";", @thisres),
|
||||
$p->{'description'};
|
||||
@ -253,7 +253,7 @@ foreach $k (sort { $a <=> $b } keys %$plist) {
|
||||
}
|
||||
print "</select><select name=res size=$sels>\n";
|
||||
foreach $r (sort { $a <=> $b} keys %gotres) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$_[1]->{'res'} eq $r ? 'selected' : '', $r;
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -266,7 +266,7 @@ printf "<input type=radio name=eof value=false %s> $text{'no'}</td>\n",
|
||||
|
||||
print "<td><b>$text{'caldera_paper'}</b></td> <td><select name=paper>\n";
|
||||
foreach $p (sort { $a cmp $b } keys %paper_sizes) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$p, $_[1]->{'paper'} eq $p ? 'selected' : '',
|
||||
$paper_sizes{$p};
|
||||
}
|
||||
@ -296,7 +296,7 @@ if ($gconfig{'os_version'} < 2.4) {
|
||||
print "<tr> <td valign=top><b>$text{'caldera_printer'}</b></td>\n";
|
||||
print "<td colspan=3><select name=uniprint size=5>\n";
|
||||
foreach $u (&list_uniprint()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$u->[0], $u->[0] eq $_[1]->{'upp'} ? 'selected' : '',
|
||||
$u->[1];
|
||||
}
|
||||
@ -311,7 +311,7 @@ if ($gconfig{'os_version'} < 2.4) {
|
||||
|
||||
print "<td><b>$text{'caldera_paper'}</b></td> <td><select name=upaper>\n";
|
||||
foreach $p (sort { $a cmp $b } keys %paper_sizes) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$p, $_[1]->{'paper'} eq $p ? 'selected' : '',
|
||||
$paper_sizes{$p};
|
||||
}
|
||||
|
@ -56,7 +56,7 @@ opendir(DIR, $config{'model_path'});
|
||||
while($f = readdir(DIR)) {
|
||||
if ($f =~ /^\./) { next; }
|
||||
$path = "$config{'model_path'}/$f";
|
||||
printf "<option value=\"$path\" %s>$f\n",
|
||||
printf "<option value=\"$path\" %s>$f</option>\n",
|
||||
$path eq $prn{'iface'} ? "selected" : "";
|
||||
}
|
||||
closedir(DIR);
|
||||
@ -73,17 +73,17 @@ if (&has_ghostscript()) {
|
||||
print "<select name=driver size=7>\n";
|
||||
foreach $d (&list_webmin_drivers()) {
|
||||
if ($drvsupp{$d->[0]}) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$d->[1] eq $drv->{'type'} ? "selected" : "",
|
||||
$d->[1];
|
||||
}
|
||||
}
|
||||
print "</select> ";
|
||||
print "<select name=dpi size=7>\n";
|
||||
printf "<option value=\"\" %s>Default\n",
|
||||
printf "<option value=\"\" %s>Default</option>\n",
|
||||
$drv->{'dpi'} ? "" : "selected";
|
||||
foreach $d (75, 100, 150, 200, 300, 600) {
|
||||
printf "<option value=\"$d\" %s>$d DPI\n",
|
||||
printf "<option value=\"$d\" %s>$d DPI</option>\n",
|
||||
$drv->{'dpi'} == $d ? "selected" : "";
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -349,7 +349,7 @@ if (&has_ghostscript()) {
|
||||
print "<select name=driver size=7>\n";
|
||||
foreach $d (&list_webmin_drivers()) {
|
||||
if ($drvsupp{$d->[0]}) {
|
||||
printf "<option value='%s' %s>%s (%s)\n",
|
||||
printf "<option value='%s' %s>%s (%s)</option>\n",
|
||||
$d->[1],
|
||||
$d->[1] eq $drv->{'type'} ? "selected" : "",
|
||||
$d->[1], $d->[0];
|
||||
@ -357,10 +357,10 @@ if (&has_ghostscript()) {
|
||||
}
|
||||
print "</select> ";
|
||||
print "<select name=dpi size=7>\n";
|
||||
printf "<option value=\"\" %s>Default\n",
|
||||
printf "<option value=\"\" %s>Default</option>\n",
|
||||
$drv->{'dpi'} ? "" : "selected";
|
||||
foreach $d (75, 100, 150, 200, 300, 600, 720, 1440) {
|
||||
printf "<option value=\"$d\" %s>$d DPI\n",
|
||||
printf "<option value=\"$d\" %s>$d DPI</option>\n",
|
||||
$drv->{'dpi'} == $d ? "selected" : "";
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -372,7 +372,7 @@ if (&has_ghostscript()) {
|
||||
print "$text{'webmin_uniprint'}</td> <td valign=top>";
|
||||
print "<select name=uniprint size=5>\n";
|
||||
foreach $u (&list_uniprint()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$u->[0],
|
||||
$u->[0] eq $drv->{'upp'} ? 'selected' : '',
|
||||
$u->[1];
|
||||
|
@ -172,7 +172,7 @@ foreach $k (sort { $a <=> $b } keys %$plist) {
|
||||
$_[1]->{'gsdevice'} eq $p->{'type'}->{'0'}) ||
|
||||
(!$_[1]->{'gsname'} && !$found &&
|
||||
$_[1]->{'gsdevice'} eq $p->{'type'}->{'0'});
|
||||
printf "<option %s value='%s'>%s\n",
|
||||
printf "<option %s value='%s'>%s</option>\n",
|
||||
$got ? 'selected' : '',
|
||||
$p->{'description'}.";".join(";", @thisres),
|
||||
$p->{'description'};
|
||||
@ -182,7 +182,7 @@ foreach $k (sort { $a <=> $b } keys %$plist) {
|
||||
}
|
||||
print "</select><select name=res size=5>\n";
|
||||
foreach $r (sort { $a <=> $b} keys %gotres) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$_[1]->{'res'} eq $r ? 'selected' : '', $r;
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -195,7 +195,7 @@ printf "<input type=radio name=eof value=false %s> $text{'no'}</td>\n",
|
||||
|
||||
print "<td><b>$text{'caldera_paper'}</b></td> <td><select name=paper>\n";
|
||||
foreach $p (sort { $a cmp $b } keys %paper_sizes) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$p, $_[1]->{'paper'} eq $p ? 'selected' : '',
|
||||
$paper_sizes{$p};
|
||||
}
|
||||
@ -221,7 +221,7 @@ print "<td><table width=100%>\n";
|
||||
print "<tr> <td valign=top><b>$text{'caldera_printer'}</b></td>\n";
|
||||
print "<td colspan=3><select name=uniprint size=5>\n";
|
||||
foreach $u (&list_uniprint()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$u->[0], $u->[0] eq $_[1]->{'upp'} ? 'selected' : '', $u->[1];
|
||||
}
|
||||
closedir(DIR);
|
||||
@ -235,7 +235,7 @@ printf "<input type=radio name=ueof value=false %s> $text{'no'}</td>\n",
|
||||
|
||||
print "<td><b>$text{'caldera_paper'}</b></td> <td><select name=upaper>\n";
|
||||
foreach $p (sort { $a cmp $b } keys %paper_sizes) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$p, $_[1]->{'paper'} eq $p ? 'selected' : '',
|
||||
$paper_sizes{$p};
|
||||
}
|
||||
|
@ -227,9 +227,9 @@ print "$text{'redhat_driver'}</td> <td><table width=100%>";
|
||||
|
||||
print "<tr> <td valign=top><b>$text{'redhat_printer2'}</b></td>\n";
|
||||
print "<td><select name=printer size=10 onChange='setdriver(0)'>\n";
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
'text', $drv->{'text'} ? 'selected' : '', "Text printer";
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
'postscript', $drv->{'postscript'} ? 'selected' : '',
|
||||
"Postscript printer";
|
||||
|
||||
@ -238,7 +238,7 @@ local $select_driver = 0;
|
||||
foreach $k (sort { lc($a) cmp lc($b) } keys %$list) {
|
||||
foreach $m (@{$list->{$k}}) {
|
||||
next if (!@{$m->{'drivers'}});
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
join(";", $m->{'id'}, @{$m->{'drivers'}}),
|
||||
$drv->{'make'} eq $k &&
|
||||
$drv->{'model'} eq $m->{'model'} ? 'selected' : '',
|
||||
@ -253,13 +253,13 @@ print "</select><select name=driver size=10 width=100></select></td> </tr>\n";
|
||||
|
||||
local $foundp = 0;
|
||||
print "<tr> <td><b>$text{'redhat_paper'}</b></td> <td><select name=paper>\n";
|
||||
print "<option value='' selected>$text{'redhat_none'}\n" if (!$drv->{'paper'});
|
||||
print "<option value='' selected>$text{'redhat_none'}</option>\n" if (!$drv->{'paper'});
|
||||
foreach $p (@paper_sizes) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$drv->{'paper'} eq $p ? 'selected' : '', $p;
|
||||
$foundp++ if ($drv->{'paper'} eq $p);
|
||||
}
|
||||
printf "<option selected>$drv->{'paper'}\n" if (!$foundp && $drv->{'paper'});
|
||||
printf "<option selected>$drv->{'paper'}</option>\n" if (!$foundp && $drv->{'paper'});
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
print "</table></td></tr>\n";
|
||||
|
@ -974,9 +974,9 @@ if (@$mail) {
|
||||
# Mark as
|
||||
print "<input type=submit name=mark$_[0] value=\"$text{'mail_mark'}\">";
|
||||
print "<select name=mode$_[0]>\n";
|
||||
print "<option value=1 checked>$text{'mail_mark1'}\n";
|
||||
print "<option value=0>$text{'mail_mark0'}\n";
|
||||
print "<option value=2>$text{'mail_mark2'}\n";
|
||||
print "<option value=1 checked>$text{'mail_mark1'}</option>\n";
|
||||
print "<option value=0>$text{'mail_mark0'}</option>\n";
|
||||
print "<option value=2>$text{'mail_mark2'}</option>\n";
|
||||
print "</select>";
|
||||
print $spacer;
|
||||
|
||||
|
@ -17,7 +17,7 @@ print "<select name=lists multiple size=3 width=150>\n";
|
||||
local (%lcan, $l);
|
||||
map { $lcan{$_}++ } split(/\s+/, $_[0]->{'lists'});
|
||||
foreach $l (@lists) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$lcan{$l} ? "selected" : "", $l;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -38,10 +38,10 @@ print <<EOF;
|
||||
|
||||
<tr> <td><b>$text{'create_archive'}</b></td>
|
||||
<td><select name=archive>
|
||||
<option value='' selected>$text{'no'}
|
||||
<option value=Y>$text{'create_archiveyear'}
|
||||
<option value=M>$text{'create_archivemonth'}
|
||||
<option value=D>$text{'create_archiveday'}
|
||||
<option value='' selected>$text{'no'}</option>
|
||||
<option value=Y>$text{'create_archiveyear'}</option>
|
||||
<option value=M>$text{'create_archivemonth'}</option>
|
||||
<option value=D>$text{'create_archiveday'}</option>
|
||||
</select></td> </tr>
|
||||
|
||||
</table></td></tr></table>
|
||||
|
@ -9,7 +9,7 @@ $access{'create'} || &error($text{'cdigest_ecannot'});
|
||||
|
||||
$lists = "<select name=list>\n";
|
||||
foreach $l (&list_lists(&get_config())) {
|
||||
$lists .= "<option>$l\n";
|
||||
$lists .= "<option>$l</option>\n";
|
||||
}
|
||||
$lists .= "</select>\n";
|
||||
|
||||
|
@ -328,7 +328,7 @@ local $v = &find_value($_[0], $_[2]);
|
||||
local $rv = "<td><b>$_[1]</b></td> <td nowrap><select name=$_[0]>";
|
||||
for($i=3; $i<@_; $i+=2) {
|
||||
local $ch = $v eq $_[$i] ? "selected" : "";
|
||||
$rv .= "<option value='$_[$i]' $ch> ".$_[$i+1];
|
||||
$rv .= "<option value='$_[$i]' $ch>".$_[$i+1]."</option>";
|
||||
}
|
||||
$rv .= "</select></td>\n";
|
||||
return $rv;
|
||||
|
@ -23,7 +23,7 @@ $authtype = &find_value("authtype", $conf);
|
||||
print "<tr> <td><b>$text{'global_authtype'}</b></td>\n";
|
||||
print "<td><select name=authtype>\n";
|
||||
foreach $t ('', 'getpwnam', 'userfile', 'shadow') {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$t, $authtype eq $t ? "selected" : "",
|
||||
$text{"global_authtype_$t"};
|
||||
}
|
||||
|
@ -49,7 +49,7 @@ printf "<input type=radio name=monitor_def value=1 %s> %s\n",
|
||||
$in{'new'} || $idx >= 0 ? "checked" : "", $text{'service_mon1'};
|
||||
print "<select name=monitor>\n";
|
||||
foreach $m (@mons) {
|
||||
printf "<option %s>%s\n", $m eq $mon ? "selected" : "", $m;
|
||||
printf "<option %s>%s</option>\n", $m eq $mon ? "selected" : "", $m;
|
||||
}
|
||||
print "</select>\n";
|
||||
printf "<input type=radio name=monitor_def value=0 %s> %s\n",
|
||||
@ -123,7 +123,7 @@ foreach $p (@periods) {
|
||||
print "<td><select name=name_$i>\n";
|
||||
foreach $p (@defperiods) {
|
||||
$p->{'value'} =~ /^(\S+):/;
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$name eq $1 ? "selected" : "", $1;
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -149,18 +149,18 @@ foreach $p (@periods) {
|
||||
if ($a->{'value'} =~ /^(\S+)\s*(.*)/) {
|
||||
$al = $1; $ar = $2;
|
||||
}
|
||||
printf "<option value='' %s> \n",
|
||||
printf "<option value='' %s> </option>\n",
|
||||
$al ? "" : "selected";
|
||||
foreach $av (@avail) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$al eq $av ? "selected" : "", $av;
|
||||
$found++ if ($al eq $av);
|
||||
}
|
||||
print "<option selected>$al\n" if (!$found && $al);
|
||||
print "<option selected>$al</option>\n" if (!$found && $al);
|
||||
print "</select></td>\n";
|
||||
print "<td><select name=atype_${i}_${j}>\n";
|
||||
foreach $t ('alert', 'upalert', 'startupalert') {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $a->{'name'} eq $t ? "selected" : "",
|
||||
$text{"service_atype_$t"};
|
||||
}
|
||||
|
@ -18,12 +18,12 @@ print "<tr $cb> <td><table width=100%>\n";
|
||||
print "<tr> <td><b>$text{'watch_group'}</b></td>\n";
|
||||
print "<td><select name=group>\n";
|
||||
foreach $s (&find("hostgroup", $conf)) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$s eq $watch->{'values'}->[0] ? "selected" : "",
|
||||
$s->{'values'}->[0];
|
||||
$found++ if ($s eq $watch->{'values'}->[0]);
|
||||
}
|
||||
print "<option selected>$watch->{'values'}->[0]\n" if (!$found);
|
||||
print "<option selected>$watch->{'values'}->[0]</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
print "<tr> <td valign=top><b>$text{'watch_services'}</b></td>\n";
|
||||
|
@ -34,7 +34,7 @@ print "<form action=create_watch.cgi>\n";
|
||||
print "<input type=submit value='$text{'watches_add'}'>\n";
|
||||
print "<select name=group>\n";
|
||||
foreach $s (&find("hostgroup", $conf)) {
|
||||
print "<option>$s->{'values'}->[0]\n";
|
||||
print "<option>$s->{'values'}->[0]</option>\n";
|
||||
}
|
||||
print "</select></form>\n";
|
||||
|
||||
|
@ -343,7 +343,7 @@ sub day_input
|
||||
local @days = ( 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun' );
|
||||
local $rv = "<select name=$_[0]>\n";
|
||||
foreach $d (@days) {
|
||||
$rv .= sprintf "<option %s>%s\n",
|
||||
$rv .= sprintf "<option %s>%s</option>\n",
|
||||
lc($d) eq lc($_[1]) ? "selected" : "", $d;
|
||||
}
|
||||
$rv .= "</select>\n";
|
||||
@ -360,7 +360,7 @@ if ($_[1] =~ /^([\d\.]+)(\S)$/) {
|
||||
$rv = "<input name=$_[0] size=6 value='$int'>\n";
|
||||
$rv .= "<select name=$_[0]_u>\n";
|
||||
foreach $u ('s', 'm', 'h', 'd') {
|
||||
$rv .= sprintf "<option value=%s %s>%s\n",
|
||||
$rv .= sprintf "<option value=%s %s>%s</option>\n",
|
||||
$u, $units eq $u ? "selected" : "", $text{"service_units_$u"};
|
||||
}
|
||||
$rv .= "</select>\n";
|
||||
|
@ -592,7 +592,7 @@ if ($_[0] eq "swap") {
|
||||
print "<tr> <td><b>Priority</b></td>\n";
|
||||
print "<td><select name=swap_pri>\n";
|
||||
for ($i = 0; $i < 11; ++$i) {
|
||||
printf "<option value=\"%s\" %s>%s\n",
|
||||
printf "<option value=\"%s\" %s>%s</option>\n",
|
||||
$i, $options{"pri"} == $i ? "selected" : "", $i;
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -607,7 +607,7 @@ if ($_[0] eq "swapfs") {
|
||||
if (!defined($options{backfstype})) { $options{backfstype} = "nfs"; }
|
||||
foreach (&list_fstypes()) {
|
||||
if ($_ eq "cachefs") { next; }
|
||||
printf "<option value=\"$_\" %s>$_\n",
|
||||
printf "<option value=\"$_\" %s>$_</option>\n",
|
||||
$_ eq $options{backfstype} ? "selected" : "";
|
||||
}
|
||||
print "</select></td>\n";
|
||||
@ -632,10 +632,10 @@ if ($_[0] eq "swapfs") {
|
||||
|
||||
print "<tr> <td><b>Consistency check</b></td>\n";
|
||||
print "<td><select name=cfs_con>\n";
|
||||
print "<option value=1> Periodically\n";
|
||||
printf "<option value=0 %s> Never\n",
|
||||
print "<option value=1>Periodically</option>\n";
|
||||
printf "<option value=0 %s>Never</option>\n",
|
||||
defined($options{"noconst"}) ? "selected" : "";
|
||||
printf "<option value=2 %s> On demand\n",
|
||||
printf "<option value=2 %s>On demand</option>\n",
|
||||
defined($options{"demandconst"}) ? "selected" : "";
|
||||
print "</select></td>\n";
|
||||
|
||||
|
@ -143,7 +143,7 @@ local $fs;
|
||||
foreach $fs (sort { &fstype_name($a) cmp &fstype_name($b) } &list_fstypes()) {
|
||||
local $nm = &fstype_name($fs);
|
||||
if (!$donefs{$nm}++ && &can_fstype($fs)) {
|
||||
print "<option value=\"$fs\">$nm ($fs)\n";
|
||||
print "<option value=\"$fs\">$nm ($fs)</option>\n";
|
||||
}
|
||||
}
|
||||
print "</select></form>\n";
|
||||
|
@ -682,12 +682,12 @@ if ($_[0] eq "nfs") {
|
||||
|
||||
print "<tr> <td><b>$text{'solaris_proto'}</b></td>\n";
|
||||
print "<td nowrap><select name=proto>\n";
|
||||
printf "<option value=\"\" %s> $text{'default'}\n",
|
||||
printf "<option value=\"\" %s>$text{'default'}</option>\n",
|
||||
defined($options{"proto"}) ? "" : "selected";
|
||||
&open_tempfile(NETCONFIG, "/etc/netconfig");
|
||||
while(<NETCONFIG>) {
|
||||
if (!/^([A-z0-9\_\-]+)\s/) { next; }
|
||||
printf "<option value=\"$1\" %s> $1\n",
|
||||
printf "<option value=\"$1\" %s>$1</option>\n",
|
||||
$options{"proto"} eq $1 ? "selected" : "";
|
||||
}
|
||||
&close_tempfile(NETCONFIG);
|
||||
@ -719,11 +719,11 @@ if ($_[0] eq "nfs") {
|
||||
defined($options{"secure"}) ? "dh" :
|
||||
defined($options{"kerberos"}) ? "krb" : "";
|
||||
print "<td><select name=nfs_auth>\n";
|
||||
printf "<option value=\"\" %s> $text{'solaris_none'}\n",
|
||||
printf "<option value=\"\" %s>$text{'solaris_none'}</option>\n",
|
||||
$nfs_auth eq "" ? "selected" : "";
|
||||
printf "<option value=dh %s> $text{'solaris_des'}\n",
|
||||
printf "<option value=dh %s>$text{'solaris_des'}</option>\n",
|
||||
$nfs_auth eq "dh" ? "selected" : "";
|
||||
printf "<option value=krb %s> $text{'solaris_krb'}\n",
|
||||
printf "<option value=krb %s>$text{'solaris_krb'}</option>\n",
|
||||
$nfs_auth eq "krb" ? "selected" : "";
|
||||
print "</select></td>\n";
|
||||
|
||||
@ -769,7 +769,7 @@ if ($_[0] eq "ufs") {
|
||||
print "<td><select name=ufs_onerror>\n";
|
||||
foreach ('panic', 'lock', 'umount', 'repair') {
|
||||
next if ($_ eq "repair" && $gconfig{'os_version'} >= 10);
|
||||
printf "<option value=\"$_\" %s> $_\n",
|
||||
printf "<option value=\"$_\" %s>$_</option>\n",
|
||||
$options{onerror} eq $_ ||
|
||||
!defined($options{onerror}) && $_ eq "panic" ? "selected" : "";
|
||||
}
|
||||
@ -817,7 +817,7 @@ if ($_[0] eq "ufs") {
|
||||
print "<td nowrap><input size=5 name=ufs_toosoon_time value='$1'>\n";
|
||||
print "<select name=ufs_toosoon_units>\n";
|
||||
foreach $u ('s', 'm', 'h', 'd', 'w', 'y') {
|
||||
printf "<option value=%s %s> %s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$u, $2 eq $u ? "selected" : "", $text{"solaris_time_$u"};
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -892,11 +892,11 @@ if ($_[0] eq "tmpfs") {
|
||||
($tmpsz = $options{size}) =~ s/[A-z]+$//g;
|
||||
print "<input name=tmpfs_size size=6 value=\"$tmpsz\">\n";
|
||||
print "<select name=tmpfs_unit>\n";
|
||||
printf "<option value=m %s> MB\n",
|
||||
printf "<option value=m %s>MB</option>\n",
|
||||
$options{"size"} =~ /m$/ ? "selected" : "";
|
||||
printf "<option value=k %s> kB\n",
|
||||
printf "<option value=k %s>kB</option>\n",
|
||||
$options{"size"} =~ /k$/ ? "selected" : "";
|
||||
printf "<option value=b %s> bytes\n",
|
||||
printf "<option value=b %s>bytes</option>\n",
|
||||
$options{"size"} !~ /(k|m)$/ ? "selected" : "";
|
||||
print "</select></td>\n";
|
||||
|
||||
@ -921,7 +921,7 @@ if ($_[0] eq "cachefs") {
|
||||
if (!defined($options{backfstype})) { $options{backfstype} = "nfs"; }
|
||||
foreach (&list_fstypes()) {
|
||||
if ($_ eq "cachefs") { next; }
|
||||
printf "<option value=\"$_\" %s>$_\n",
|
||||
printf "<option value=\"$_\" %s>$_</option>\n",
|
||||
$_ eq $options{backfstype} ? "selected" : "";
|
||||
}
|
||||
print "</select></td>\n";
|
||||
@ -946,10 +946,10 @@ if ($_[0] eq "cachefs") {
|
||||
|
||||
print "<tr> <td><b>$text{'solaris_con'}</b></td>\n";
|
||||
print "<td><select name=cfs_con>\n";
|
||||
print "<option value=1> $text{'solaris_period'}\n";
|
||||
printf "<option value=0 %s> $text{'solaris_never'}\n",
|
||||
print "<option value=1>$text{'solaris_period'}</option>\n";
|
||||
printf "<option value=0 %s>$text{'solaris_never'}</option>\n",
|
||||
defined($options{"noconst"}) ? "selected" : "";
|
||||
printf "<option value=2 %s> $text{'solaris_demand'}\n",
|
||||
printf "<option value=2 %s>$text{'solaris_demand'}</option>\n",
|
||||
defined($options{"demandconst"}) ? "selected" : "";
|
||||
print "</select></td>\n";
|
||||
|
||||
@ -1075,11 +1075,11 @@ if ($_[0] eq "xmemfs") {
|
||||
($tmpsz = $options{size}) =~ s/[A-z]+$//g;
|
||||
print "<input name=xmemfs_size size=6 value=\"$tmpsz\">\n";
|
||||
print "<select name=xmemfs_unit>\n";
|
||||
printf "<option value=m %s> MB\n",
|
||||
printf "<option value=m %s>MB</option>\n",
|
||||
$options{"size"} =~ /m$/ ? "selected" : "";
|
||||
printf "<option value=k %s> kB\n",
|
||||
printf "<option value=k %s>kB</option>\n",
|
||||
$options{"size"} =~ /k$/ ? "selected" : "";
|
||||
printf "<option value=b %s> bytes\n",
|
||||
printf "<option value=b %s>bytes</option>\n",
|
||||
$options{"size"} !~ /(k|m)$/ ? "selected" : "";
|
||||
print "</select></td>\n";
|
||||
|
||||
|
@ -14,7 +14,7 @@ printf "<input type=radio name=dbs_def value=0 %s> %s<br>\n",
|
||||
print "<select name=dbs size=3 multiple width=100>\n";
|
||||
map { $dcan{$_}++ } split(/\s+/, $_[0]->{'dbs'});
|
||||
foreach $d (&list_databases()) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$dcan{$d} ? 'selected' : '', $d;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -139,7 +139,7 @@ map { $inall{$_}++ } @all;
|
||||
print "<tr> <td rowspan=4 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=4><select multiple size=6 name=tables>\n";
|
||||
foreach $t (&unique(@nis_tables, @all)) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -146,7 +146,7 @@ map { $inall{$_}++ } split(/\s+/, $rule->{'all'}->{'value'});
|
||||
print "<tr> <td rowspan=2 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=2><select multiple size=5 name=tables>\n";
|
||||
foreach $t (grep { $rule->{$_} } @nis_tables) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -147,7 +147,7 @@ map { $inall{$_}++ } split(/\s+/,&expand_vars($rule->{'all'}->{'value'}, $var));
|
||||
print "<tr> <td rowspan=2 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=2><select multiple size=5 name=tables>\n";
|
||||
foreach $t (grep { $rule->{$_} } @nis_tables) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -46,11 +46,11 @@ print "<td><input name=home size=25 value=\"$passwd->[5]\"> ",
|
||||
print "<tr> <td valign=top><b>$text{'passwd_shell'}</b></td>\n";
|
||||
print "<td valign=top><select name=shell>\n";
|
||||
foreach $s (&unique(@shlist)) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$passwd->[6] eq $s ? 'selected' : '', $s;
|
||||
$found++ if ($passwd->[6] eq $s);
|
||||
}
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? '' : 'selected', $text{'passwd_other'};
|
||||
print "</select><br>\n";
|
||||
printf "<input name=other size=20 value='%s'> %s</td>\n",
|
||||
|
@ -23,7 +23,7 @@ print "<td><input name=name size=15 value='$name'></td>\n";
|
||||
print "<td><b>$text{'services_proto'}</b></td>\n";
|
||||
print "<td><select name=proto>\n";
|
||||
foreach $p (&foreign_call("inetd", "list_protocols")) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, $proto eq $p || !$proto && $p eq 'tcp' ? 'selected' : '',
|
||||
uc($p);
|
||||
}
|
||||
|
@ -29,7 +29,7 @@ foreach $t (@tables) {
|
||||
$t->{'desc'} = $text{"desc_".$t->{'table'}};
|
||||
$t->{'desc'} = $t->{'table'} if (!$t->{'desc'});
|
||||
$t->{'desc'} .= " ($t->{'domain'})" if (@domains > 1);
|
||||
printf "<option value=%d %s>%s\n",
|
||||
printf "<option value=%d %s>%s</option>\n",
|
||||
$t->{'index'}, $in{'table'} eq $t->{'index'} ? 'selected' : '',
|
||||
$t->{'desc'};
|
||||
}
|
||||
@ -160,7 +160,7 @@ if ($config{'max_size'} && $lines > $config{'max_size'}) {
|
||||
local $sel = "<select name=field>\n";
|
||||
local $n = 0;
|
||||
foreach $f (@{$_[0]}) {
|
||||
$sel .= sprintf "<option value=%s %s>%s\n",
|
||||
$sel .= sprintf "<option value=%s %s>%s</option>\n",
|
||||
$n, $in{'field'} == $n ? 'selected' : '', $f;
|
||||
$n++;
|
||||
}
|
||||
|
@ -127,7 +127,7 @@ print "<input name=$_[3]d size=3 value='$_[0]'>";
|
||||
print "/<select name=$_[3]m>\n";
|
||||
local $m;
|
||||
foreach $m (1..12) {
|
||||
printf "<option value=%d %s>%s\n",
|
||||
printf "<option value=%d %s>%s</option>\n",
|
||||
$m, $_[1] eq $m ? 'selected' : '', $text{"smonth_$m"};
|
||||
}
|
||||
print "</select>";
|
||||
|
@ -43,11 +43,11 @@ print "<td><input name=home size=25 value=\"$passwd->[5]\"> ",
|
||||
print "<tr> <td valign=top><b>$text{'passwd_shell'}</b></td>\n";
|
||||
print "<td valign=top><select name=shell>\n";
|
||||
foreach $s (&unique(@shlist)) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$passwd->[6] eq $s ? 'selected' : '', $s;
|
||||
$found++ if ($passwd->[6] eq $s);
|
||||
}
|
||||
printf "<option %s>%s\n", $found ? '' : 'selected', $text{'passwd_other'};
|
||||
printf "<option %s>%s</option>\n", $found ? '' : 'selected', $text{'passwd_other'};
|
||||
print "</select><br>\n";
|
||||
printf "<input name=other size=20 value='%s'> %s</td>\n",
|
||||
$found ? '' : $passwd->[6], &file_chooser_button("other");
|
||||
|
@ -38,13 +38,13 @@ foreach $s (@switch) {
|
||||
print "<td><select name=order_${sv}_${i}>\n";
|
||||
foreach $sc (@sources) {
|
||||
if ($sc =~ /(\S+)=(\S+)/ && $1 eq $sv) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$2,
|
||||
$o[$i-1] eq $2 ? 'selected' : '',
|
||||
$text{"order_$2"};
|
||||
}
|
||||
elsif ($sc !~ /=/) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$sc,
|
||||
$o[$i-1] eq $sc ? 'selected' : '',
|
||||
$text{"order_$sc"};
|
||||
|
@ -121,7 +121,7 @@ foreach $d (@domains) {
|
||||
print "<td valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td><select name=tables_$n size=6 multiple>\n";
|
||||
foreach $c (@conf) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$c->{'table'}, $c->{'active'} ? 'selected' : '',
|
||||
$c->{'table'};
|
||||
}
|
||||
|
@ -146,7 +146,7 @@ map { $inall{$_}++ } split(/\s+/, $rule->{'all'}->{'value'});
|
||||
print "<tr> <td rowspan=2 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=2><select multiple size=5 name=tables>\n";
|
||||
foreach $t (grep { $rule->{$_} } @nis_tables) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -146,7 +146,7 @@ map { $inall{$_}++ } split(/\s+/, $rule->{'all'}->{'value'});
|
||||
print "<tr> <td rowspan=2 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=2><select multiple size=5 name=tables>\n";
|
||||
foreach $t (grep { $rule->{$_} } @nis_tables) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -137,7 +137,7 @@ map { $inall{$_}++ } @all;
|
||||
print "<tr> <td rowspan=4 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=4><select multiple size=6 name=tables>\n";
|
||||
foreach $t (&unique(@nis_tables, @all)) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -157,7 +157,7 @@ map { $inall{$_}++ } split(/\s+/, $rule->{'all'}->{'value'});
|
||||
print "<tr> <td rowspan=2 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=2><select multiple size=5 name=tables>\n";
|
||||
foreach $t (grep { $rule->{$_} } @nis_tables) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -153,7 +153,7 @@ map { $inall{$_}++ } split(/\s+/, $rule->{'all'}->{'value'});
|
||||
print "<tr> <td rowspan=2 valign=top><b>$text{'server_tables'}</b></td>\n";
|
||||
print "<td rowspan=2><select multiple size=5 name=tables>\n";
|
||||
foreach $t (grep { $rule->{$_} } @nis_tables) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $inall{$t} ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -31,13 +31,13 @@ foreach $t (sort { "$a$b" =~ /^\/dev\/ttyS(\d+)\/dev\/ttyS(\d+)$/ ? $1 <=> $2 :
|
||||
glob($config{'serials'})) {
|
||||
$t =~ s/^\/dev\///;
|
||||
local $f = $init->{'tty'} eq $t || $init->{'tty'} eq "/dev/$t";
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $f ? "selected" : "",
|
||||
$t =~ /^ttyS(\d+)$/ ? &text('mgetty_ts', $1+1) :
|
||||
$t =~ /^term\/(\S+)$/ ? &text('mgetty_ts', uc($1)) : "/dev/$t";
|
||||
$found++ if ($f);
|
||||
}
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'mgetty_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=other size=20 value='%s'> %s</td>\n",
|
||||
|
@ -104,11 +104,11 @@ $modem = &find("modem", \@opts);
|
||||
$local = &find("local", \@opts);
|
||||
print "<td><b>$text{'options_ctrl'}</b></td>\n";
|
||||
print "<td><select name=ctrl>\n";
|
||||
printf "<option value=0 %s> %s\n",
|
||||
printf "<option value=0 %s>%s</option>\n",
|
||||
$local ? "selected" : "", $text{'options_ctrl0'};
|
||||
printf "<option value=1 %s> %s\n",
|
||||
printf "<option value=1 %s>%s</option>\n",
|
||||
$modem ? "selected" : "", $text{'options_ctrl1'};
|
||||
printf "<option value=2 %s> %s\n",
|
||||
printf "<option value=2 %s>%s</option>\n",
|
||||
$modem || $local ? "" : "selected", $text{'default'};
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
|
@ -18,7 +18,7 @@ if (@listdb) {
|
||||
print "<select name=dbs size=5 multiple width=100>\n";
|
||||
map { $dcan{$_}++ } split(/\s+/, $_[0]->{'dbs'});
|
||||
foreach $d (@listdb) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$dcan{$d} ? 'selected' : '', $d;
|
||||
}
|
||||
print "</select>";
|
||||
|
@ -72,7 +72,7 @@ printf "<input type=radio name=inherits_def value=0 %s> %s\n",
|
||||
print "<select name=inherits>\n";
|
||||
foreach $c (@$conf) {
|
||||
next if ($c eq $dialer);
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$c->{'name'}, lc($inherits) eq lc($c->{'name'}) ? "selected":"",
|
||||
&dialer_name($c->{'name'});
|
||||
}
|
||||
@ -86,20 +86,20 @@ $dm = &get_default("Modem");
|
||||
local $found = !$modem || $modem eq "/dev/modem";
|
||||
print "<tr> <td><b>$text{'edit_serial'}</b></td>\n";
|
||||
print "<td nowrap><select name=modem>\n";
|
||||
printf "<option value='' %s>%s %s\n",
|
||||
printf "<option value='' %s>%s %s</option>\n",
|
||||
$modem ? "" : "selected",
|
||||
$defs ? $text{'edit_none'} : $text{'edit_def'},
|
||||
$dm ? "($dm)" : "";
|
||||
printf "<option value=/dev/modem %s>%s (%s)\n",
|
||||
printf "<option value=/dev/modem %s>%s (%s)</option>\n",
|
||||
$modem eq "/dev/modem" ? "selected" : "", $text{'edit_modem'},
|
||||
"/dev/modem";
|
||||
foreach $t (sort { "$a$b" =~ /^\/dev\/ttyS(\d+)\/dev\/ttyS(\d+)$/ ? $1 <=> $2 : 0 } glob("/dev/ttyS[0-9]*")) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $modem eq $t ? "selected" : "",
|
||||
$t =~ /ttyS(\d+)$/ ? &text('edit_port', $1+1) : $t;
|
||||
$found++ if ($modem eq $t);
|
||||
}
|
||||
printf "<option value=* %s>%s\n",
|
||||
printf "<option value=* %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'edit_otherm'};
|
||||
print "</select>\n";
|
||||
printf "<input name=otherm size=15 value='%s'></td>\n",
|
||||
|
@ -88,7 +88,7 @@ else {
|
||||
"value='$text{'index_connect'}'>\n";
|
||||
print "<select name=section>\n";
|
||||
foreach $c (@dials) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$c->{'name'},
|
||||
$c->{'name'} eq $config{'dialer'} ?
|
||||
"selected" : "",
|
||||
@ -110,11 +110,11 @@ else {
|
||||
print "<input type=hidden name=starting value='$starting'>\n";
|
||||
print "<td nowrap><input type=submit value='$text{'index_boot'}'>\n";
|
||||
print "<select name=section>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$config{'boot'} ? "" : "selected",
|
||||
$text{'index_noboot'};
|
||||
foreach $c (@dials) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$c->{'name'},
|
||||
$c->{'name'} eq $config{'boot'} ?
|
||||
"selected" : "",
|
||||
|
@ -147,7 +147,7 @@ foreach $r (@kroutes, [ 0, undef, undef, 'GW' ]) {
|
||||
print "<tr $cb>\n";
|
||||
print "<td><select name=type_$i>\n";
|
||||
foreach $o (0 .. 2) {
|
||||
printf "<option value=%d %s>%s\n",
|
||||
printf "<option value=%d %s>%s</option>\n",
|
||||
$o, $r->[0] == $o ? "selected" : "",
|
||||
$text{'edit_type'.$o};
|
||||
}
|
||||
|
@ -58,7 +58,7 @@ else {
|
||||
print "<input type=submit value='$text{'index_conn'}'>\n";
|
||||
print "<select name=tunnel>\n";
|
||||
foreach $t (@notconns) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$config{'tunnel'} eq $t->{'name'} ? "selected" : "",
|
||||
$t->{'name'};
|
||||
}
|
||||
@ -74,7 +74,7 @@ else {
|
||||
print "<input type=submit value='$text{'index_disc'}'>\n";
|
||||
print "<select name=tunnel>\n";
|
||||
foreach $t (@conns) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$config{'tunnel'} eq $t->[0] ? "selected" : "",
|
||||
$t->[0];
|
||||
}
|
||||
@ -92,11 +92,11 @@ else {
|
||||
print "<input type=hidden name=starting value='$starting'>\n";
|
||||
print "<td nowrap><input type=submit value='$text{'index_boot'}'>\n";
|
||||
print "<select name=tunnel>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$config{'boot'} ? "" : "selected",
|
||||
$text{'index_noboot'};
|
||||
foreach $t (@tunnels) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$t->{'name'},
|
||||
$t->{'name'} eq $config{'boot'} ?
|
||||
"selected" : "",
|
||||
|
@ -199,7 +199,7 @@ if (%in) {
|
||||
join(" ", @pidlist);
|
||||
print "<select name=signal>\n";
|
||||
foreach $s (&supported_signals()) {
|
||||
printf "<option value=\"$s\" %s> $s\n",
|
||||
printf "<option value=\"$s\" %s>$s</option>\n",
|
||||
$s eq "HUP" ? "selected" : "";
|
||||
}
|
||||
print "</select>\n";
|
||||
|
@ -14,7 +14,7 @@ print "<form action=allmanual_form.cgi>\n";
|
||||
print "<input type=submit value='$text{'manual_file'}'>\n";
|
||||
print "<select name=file>\n";
|
||||
foreach $f (@files) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$f eq $in{'file'} ? 'selected' : '', $f;
|
||||
$found++ if ($f eq $in{'file'});
|
||||
}
|
||||
|
@ -50,12 +50,12 @@ map { $cmd{lc($_)}++ } @{$l->{'words'}};
|
||||
print "<tr> <td valign=top><b>$text{'lserv_cmd'}</b></td>\n";
|
||||
print "<td><select name=cmd multiple size=7 width=120>\n";
|
||||
foreach $c ('cwd', 'mkd', 'rnfr', 'dele', 'rmd', 'retr', 'stor') {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
uc($c), $cmd{$c} ? "selected" : "", uc($c);
|
||||
}
|
||||
print "</select><select name=cmd multiple size=7 width=120>\n";
|
||||
foreach $c ('site_chmod', 'read', 'write', 'dirs', 'login', 'all') {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
uc($c), $cmd{$c} ? "selected" : "", uc($c);
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -393,11 +393,11 @@ foreach $c (@{$_[0]}, { }) {
|
||||
$rv .= "<tr $cb>\n";
|
||||
$rv .= "<td><input name=Class_n_$i size=10 value='$w[0]'></td>\n";
|
||||
$rv .= "<td><select name=Class_t_$i>\n";
|
||||
$rv .= sprintf "<option value=limit %s>%s\n",
|
||||
$rv .= sprintf "<option value=limit %s>%s</option>\n",
|
||||
$w[1] eq 'limit' ? 'selected' : '', $text{'mod_core_climit'};
|
||||
$rv .= sprintf "<option value=regex %s>%s\n",
|
||||
$rv .= sprintf "<option value=regex %s>%s</option>\n",
|
||||
$w[1] eq 'regex' ? 'selected' : '', $text{'mod_core_cregex'};
|
||||
$rv .= sprintf "<option value=ip %s>%s\n",
|
||||
$rv .= sprintf "<option value=ip %s>%s</option>\n",
|
||||
$w[1] eq 'ip' ? 'selected' : '', $text{'mod_core_cip'};
|
||||
$rv .= "</select>\n";
|
||||
$rv .= "<input name=Class_v_$i size=20 value='$w[2]'></td>\n";
|
||||
|
@ -427,7 +427,7 @@ local($i, $rv);
|
||||
$rv = "<select name=\"$_[1]\">\n";
|
||||
for($i=3; $i<@_; $i++) {
|
||||
$_[$i] =~ /^([^,]*),(.*)$/;
|
||||
$rv .= sprintf "<option value=\"$2\" %s> $1\n",
|
||||
$rv .= sprintf "<option value=\"$2\" %s>$1</option>\n",
|
||||
lc($2) eq lc($_[0]) || !defined($_[0]) && lc($2) eq lc($_[2]) ? "selected" : "";
|
||||
}
|
||||
$rv .= "</select>\n";
|
||||
|
@ -709,11 +709,11 @@ elsif (-d $fullname) {
|
||||
print "<SELECT NAME=only_with_tag";
|
||||
print " onchange=\"submit()\"" if ($use_java_script);
|
||||
print ">";
|
||||
print "<OPTION VALUE=\"\">All tags / default branch\n";
|
||||
print "<OPTION VALUE=\"\">All tags / default branch</OPTION>\n";
|
||||
foreach my $tag (reverse sort { lc $a cmp lc $b } keys %tags) {
|
||||
print "<OPTION",defined($input{only_with_tag}) &&
|
||||
$input{only_with_tag} eq $tag ? " SELECTED":"",
|
||||
">$tag\n";
|
||||
">$tag</OPTION>\n";
|
||||
}
|
||||
print "</SELECT>\n";
|
||||
print "<INPUT TYPE=SUBMIT VALUE=\"Go\">\n";
|
||||
@ -731,18 +731,18 @@ elsif (-d $fullname) {
|
||||
print "<center><table cellpadding=0 cellspacing=0>";
|
||||
print "<tr bgcolor=\"$columnHeaderColorDefault\"><th colspan=2>Preferences</th></tr>";
|
||||
print "<tr><td>Sort files by <SELECT name=\"sortby\">";
|
||||
print "<OPTION VALUE=\"\">File";
|
||||
print "<OPTION",$bydate ? " SELECTED" : ""," VALUE=date>Age";
|
||||
print "<OPTION",$byauthor ? " SELECTED" : ""," VALUE=author>Author"
|
||||
print "<OPTION VALUE=\"\">File</OPTION>";
|
||||
print "<OPTION",$bydate ? " SELECTED" : ""," VALUE=date>Age</OPTION>";
|
||||
print "<OPTION",$byauthor ? " SELECTED" : ""," VALUE=author>Author</OPTION>"
|
||||
if ($show_author);
|
||||
print "<OPTION",$byrev ? " SELECTED" : ""," VALUE=rev>Revision";
|
||||
print "<OPTION",$bylog ? " SELECTED" : ""," VALUE=log>Log message";
|
||||
print "<OPTION",$byrev ? " SELECTED" : ""," VALUE=rev>Revision</OPTION>";
|
||||
print "<OPTION",$bylog ? " SELECTED" : ""," VALUE=log>Log message</OPTION>";
|
||||
print "</SELECT></td>";
|
||||
print "<td>revisions by: \n";
|
||||
print "<SELECT NAME=logsort>\n";
|
||||
print "<OPTION VALUE=cvs",$logsort eq "cvs" ? " SELECTED" : "", ">Not sorted";
|
||||
print "<OPTION VALUE=date",$logsort eq "date" ? " SELECTED" : "", ">Commit date";
|
||||
print "<OPTION VALUE=rev",$logsort eq "rev" ? " SELECTED" : "", ">Revision";
|
||||
print "<OPTION VALUE=cvs",$logsort eq "cvs" ? " SELECTED" : "", ">Not sorted</OPTION>";
|
||||
print "<OPTION VALUE=date",$logsort eq "date" ? " SELECTED" : "", ">Commit date</OPTION>";
|
||||
print "<OPTION VALUE=rev",$logsort eq "rev" ? " SELECTED" : "", ">Revision</OPTION>";
|
||||
print "</SELECT></td></tr>";
|
||||
print "<tr><td>Diff format: ";
|
||||
printDiffSelect(0);
|
||||
@ -842,11 +842,11 @@ sub printDiffSelect($) {
|
||||
print "<SELECT NAME=\"f\"";
|
||||
print " onchange=\"submit()\"" if ($use_java_script);
|
||||
print ">\n";
|
||||
print "<OPTION VALUE=h",$f eq "h" ? " SELECTED" : "", ">Colored Diff";
|
||||
print "<OPTION VALUE=H",$f eq "H" ? " SELECTED" : "", ">Long Colored Diff";
|
||||
print "<OPTION VALUE=u",$f eq "u" ? " SELECTED" : "", ">Unidiff";
|
||||
print "<OPTION VALUE=c",$f eq "c" ? " SELECTED" : "", ">Context Diff";
|
||||
#print "<OPTION VALUE=s",$f eq "s" ? " SELECTED" : "", ">Side by Side";
|
||||
print "<OPTION VALUE=h",$f eq "h" ? " SELECTED" : "", ">Colored Diff</OPTION>";
|
||||
print "<OPTION VALUE=H",$f eq "H" ? " SELECTED" : "", ">Long Colored Diff</OPTION>";
|
||||
print "<OPTION VALUE=u",$f eq "u" ? " SELECTED" : "", ">Unidiff</OPTION>";
|
||||
print "<OPTION VALUE=c",$f eq "c" ? " SELECTED" : "", ">Context Diff</OPTION>";
|
||||
#print "<OPTION VALUE=s",$f eq "s" ? " SELECTED" : "", ">Side by Side</OPTION>";
|
||||
print "</SELECT>";
|
||||
}
|
||||
|
||||
@ -1856,7 +1856,7 @@ sub readLog($;$) {
|
||||
}
|
||||
$revsym{$rev} .= ", " if ($revsym{$rev});
|
||||
$revsym{$rev} .= $_;
|
||||
$sel .= "<OPTION VALUE=\"${rev}:${_}\">$_\n";
|
||||
$sel .= "<OPTION VALUE=\"${rev}:${_}\">$_</OPTION>\n";
|
||||
}
|
||||
print "Done associating revisions with branches\n" if ($verbose);
|
||||
|
||||
@ -2127,7 +2127,7 @@ sub doLog($) {
|
||||
}
|
||||
print "Diffs between \n";
|
||||
print "<SELECT NAME=\"r1\">\n";
|
||||
print "<OPTION VALUE=\"text\" SELECTED>Use Text Field\n";
|
||||
print "<OPTION VALUE=\"text\" SELECTED>Use Text Field</OPTION>\n";
|
||||
print $sel;
|
||||
print "</SELECT>\n";
|
||||
$diffrev = $revdisplayorder[$#revdisplayorder];
|
||||
@ -2135,7 +2135,7 @@ sub doLog($) {
|
||||
print "<INPUT TYPE=\"TEXT\" SIZE=\"$inputTextSize\" NAME=\"tr1\" VALUE=\"$diffrev\" onChange='document.diff_select.r1.selectedIndex=0'>\n";
|
||||
print " and \n";
|
||||
print "<SELECT NAME=\"r2\">\n";
|
||||
print "<OPTION VALUE=\"text\" SELECTED>Use Text Field\n";
|
||||
print "<OPTION VALUE=\"text\" SELECTED>Use Text Field</OPTION>\n";
|
||||
print $sel;
|
||||
print "</SELECT>\n";
|
||||
$diffrev = $revdisplayorder[0];
|
||||
@ -2165,12 +2165,12 @@ sub doLog($) {
|
||||
print "<OPTION VALUE=\"\"";
|
||||
print " SELECTED" if (defined($input{"only_with_tag"}) &&
|
||||
$input{"only_with_tag"} eq "");
|
||||
print ">Show all branches\n";
|
||||
print ">Show all branches</OPTION>\n";
|
||||
foreach (reverse sort @branchnames) {
|
||||
print "<OPTION";
|
||||
print " SELECTED" if (defined($input{"only_with_tag"})
|
||||
&& $input{"only_with_tag"} eq $_);
|
||||
print ">${_}\n";
|
||||
print ">${_}</OPTION>\n";
|
||||
}
|
||||
print "</SELECT>\n";
|
||||
print "<INPUT TYPE=SUBMIT VALUE=\" View Branch \">\n";
|
||||
@ -2191,9 +2191,9 @@ sub doLog($) {
|
||||
print "<SELECT NAME=\"logsort\"";
|
||||
print " onchange=\"submit()\"" if ($use_java_script);
|
||||
print ">\n";
|
||||
print "<OPTION VALUE=cvs",$logsort eq "cvs" ? " SELECTED" : "", ">Not sorted";
|
||||
print "<OPTION VALUE=date",$logsort eq "date" ? " SELECTED" : "", ">Commit date";
|
||||
print "<OPTION VALUE=rev",$logsort eq "rev" ? " SELECTED" : "", ">Revision";
|
||||
print "<OPTION VALUE=cvs",$logsort eq "cvs" ? " SELECTED" : "", ">Not sorted</OPTION>";
|
||||
print "<OPTION VALUE=date",$logsort eq "date" ? " SELECTED" : "", ">Commit date</OPTION>";
|
||||
print "<OPTION VALUE=rev",$logsort eq "rev" ? " SELECTED" : "", ">Revision</OPTION>";
|
||||
print "</SELECT>\n";
|
||||
print "<INPUT TYPE=SUBMIT VALUE=\" Sort \">\n";
|
||||
print "</FORM>\n";
|
||||
|
@ -28,16 +28,16 @@ $i = 0;
|
||||
foreach $f (@filter, [ 1, '', '', '' ]) {
|
||||
$field = "<select name=field_$i>\n";
|
||||
foreach $ft ('', 'from', 'to', 'subject', 'cc', 'body') {
|
||||
$field .= sprintf "<option value='%s' %s>%s\n",
|
||||
$field .= sprintf "<option value='%s' %s>%s</option>\n",
|
||||
$ft, $f->[2] eq $ft ? "selected" : "",
|
||||
$ft ? $text{"ffile_$ft"} : " ";
|
||||
}
|
||||
$field .= "</select>\n";
|
||||
|
||||
$what = "<select name=what_$i>\n";
|
||||
$what .= sprintf "<option value=0 %s>%s\n",
|
||||
$what .= sprintf "<option value=0 %s>%s</option>\n",
|
||||
$f->[0] == 0 ? "selected" : "", $text{"ffile_what0"};
|
||||
$what .= sprintf "<option value=1 %s>%s\n",
|
||||
$what .= sprintf "<option value=1 %s>%s</option>\n",
|
||||
$f->[0] == 1 ? "selected" : "", $text{"ffile_what1"};
|
||||
$what .= "</select>\n";
|
||||
|
||||
|
@ -90,10 +90,10 @@ if ($n =~ /^(\S+)-(\S+)$/) {
|
||||
if (@virts) {
|
||||
printf "<td><input name=name size=20 value=\"%s\">\@", $n;
|
||||
print "<select name=virt>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$virt ? "" : "checked", $text{'aform_novirt'};
|
||||
foreach $v (@virts) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$v->{'prepend'}, $virt eq $v ? "selected" : "",
|
||||
$v->{'domain'};
|
||||
}
|
||||
@ -108,7 +108,7 @@ for($i=0; $i<=@values; $i++) {
|
||||
print "<tr> <td valign=top><b>$text{'aform_val'}</b></td>\n";
|
||||
print "<td><select name=type_$i>\n";
|
||||
for($j=0; $j<@typenames; $j++) {
|
||||
printf "<option value=$j %s>$typenames[$j]\n",
|
||||
printf "<option value=$j %s>$typenames[$j]</option>\n",
|
||||
$type == $j ? "selected" : "";
|
||||
}
|
||||
print "</select>\n";
|
||||
|
@ -72,11 +72,11 @@ printf "<input type=radio name=manual value=0 %s> $text{'no'}</td>\n",
|
||||
$_[0]->{'manual'} ? "" : "checked";
|
||||
|
||||
print "<td><b>$text{'acl_mailq'}</b></td> <td><select name=mailq>\n";
|
||||
printf "<option value=2 %s> $text{'acl_viewdel'}\n",
|
||||
printf "<option value=2 %s>$text{'acl_viewdel'}</option>\n",
|
||||
$_[0]->{'mailq'} == 2 ? "selected" : "";
|
||||
printf "<option value=1 %s> $text{'acl_view'}\n",
|
||||
printf "<option value=1 %s>$text{'acl_view'}</option>\n",
|
||||
$_[0]->{'mailq'} == 1 ? "selected" : "";
|
||||
printf "<option value=0 %s> $text{'no'}\n",
|
||||
printf "<option value=0 %s>$text{'no'}</option>\n",
|
||||
$_[0]->{'mailq'} == 0 ? "selected" : "";
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
|
@ -63,7 +63,7 @@ elsif ($feature->{'type'} == 1) {
|
||||
print "<tr> <td><b>$text{'feature_feat'}</b></td>\n";
|
||||
print "<td><select name=name>\n";
|
||||
foreach $f (&list_feature_types()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$f->[0], $feature->{'name'} eq $f->[0] ? 'selected' : '',
|
||||
$f->[1];
|
||||
}
|
||||
@ -82,12 +82,12 @@ elsif ($feature->{'type'} == 2 || $feature->{'type'} == 3) {
|
||||
print "<tr> <td><b>$text{'feature_def'}</b></td>\n";
|
||||
print "<td><select name=name>\n";
|
||||
foreach $d (&list_define_types()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$d->[0], $d->[0] eq $feature->{'name'} ? "selected" : "",
|
||||
$d->[1];
|
||||
$found++ if ($d->[0] eq $feature->{'name'});
|
||||
}
|
||||
print "<option value=$feature->{'name'} selected>$feature->{'name'}\n"
|
||||
print "<option value=$feature->{'name'} selected>$feature->{'name'}</option>\n"
|
||||
if (!$found && !$in{'new'});
|
||||
print "</select>\n";
|
||||
|
||||
@ -106,7 +106,7 @@ elsif ($feature->{'type'} == 4) {
|
||||
print "<tr> <td><b>$text{'feature_mailer'}</b></td>\n";
|
||||
print "<td><select name=mailer>\n";
|
||||
foreach $m (&list_mailer_types()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$m->[0], $feature->{'mailer'} eq $m->[0] ? 'selected' : '',
|
||||
$m->[1];
|
||||
}
|
||||
@ -117,7 +117,7 @@ elsif ($feature->{'type'} == 5) {
|
||||
print "<tr> <td><b>$text{'feature_ostype'}</b></td>\n";
|
||||
print "<td><select name=ostype>\n";
|
||||
foreach $m (&list_ostype_types()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$m->[0], $feature->{'ostype'} eq $m->[0] ? 'selected' : '',
|
||||
$m->[1];
|
||||
}
|
||||
|
@ -38,16 +38,16 @@ foreach $f (@filter, [ 1, '', '', '' ],
|
||||
[ 1, '', '', '' ]) {
|
||||
$field = "<select name=field_$i>\n";
|
||||
foreach $ft ('', 'from', 'to', 'subject', 'cc', 'body') {
|
||||
$field .= sprintf "<option value='%s' %s>%s\n",
|
||||
$field .= sprintf "<option value='%s' %s>%s</option>\n",
|
||||
$ft, $f->[2] eq $ft ? "selected" : "",
|
||||
$ft ? $text{"ffile_$ft"} : " ";
|
||||
}
|
||||
$field .= "</select>\n";
|
||||
|
||||
$what = "<select name=what_$i>\n";
|
||||
$what .= sprintf "<option value=0 %s>%s\n",
|
||||
$what .= sprintf "<option value=0 %s>%s</option>\n",
|
||||
$f->[0] == 0 ? "selected" : "", $text{"ffile_what0"};
|
||||
$what .= sprintf "<option value=1 %s>%s\n",
|
||||
$what .= sprintf "<option value=1 %s>%s</option>\n",
|
||||
$f->[0] == 1 ? "selected" : "", $text{"ffile_what1"};
|
||||
$what .= "</select>\n";
|
||||
|
||||
|
@ -55,7 +55,7 @@ if (@features) {
|
||||
print "<input type=submit value='$text{'features_add'}'>\n";
|
||||
print "<select name=type>\n";
|
||||
foreach $i (0, 1, 2, 4, 5) {
|
||||
print "<option value=$i>",$text{'features_type'.$i},"\n";
|
||||
print "<option value=$i>",$text{'features_type'.$i},"</option>\n";
|
||||
}
|
||||
print "</select></td>\n";
|
||||
print "<td align=right><input type=submit name=manual ",
|
||||
|
@ -90,7 +90,7 @@ if (@qfiles) {
|
||||
print "<select name=field>\n";
|
||||
foreach $f ('from', 'subject', 'to', 'cc', 'date', 'status', 'body', 'headers', 'size', '',
|
||||
'!from', '!subject', '!to', '!cc', '!date', '!status', '!body', '!headers', '!size') {
|
||||
printf "<option value='%s'>%s\n", $f, $text{"match_$f"};
|
||||
printf "<option value='%s'>%s</option>\n", $f, $text{"match_$f"};
|
||||
}
|
||||
print "</select>\n";
|
||||
print "<input name=match size=20>\n";
|
||||
|
@ -56,15 +56,15 @@ print "<td colspan=3 nowrap>\n";
|
||||
for($i=0; $i<@allmods || $i<@mods; $i++) {
|
||||
print $i+1,". ";
|
||||
print "<select name=mod_$i>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$mods[$i] ? "" : "selected", " ";
|
||||
foreach $a (@allmods) {
|
||||
local $t = $text{'mod_'.$a};
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$a, $mods[$i] eq $a ? "selected" : "",
|
||||
$t ? $t : $a;
|
||||
}
|
||||
print "<option selected>$mods[$i]\n"
|
||||
print "<option selected>$mods[$i]</option>\n"
|
||||
if ($mods[$i] && &indexof($mods[$i], @allmods) < 0);
|
||||
print "</select>\n";
|
||||
print "<br>\n" if ($i%2);
|
||||
|
@ -16,7 +16,7 @@ local @servers = sort { $a->{'host'} cmp $b->{'host'} } &list_servers();
|
||||
local ($z, %zcan);
|
||||
map { $zcan{$_}++ } split(/\s+/, $_[0]->{'servers'});
|
||||
foreach $z (sort { $a->{'value'} cmp $b->{'value'} } @servers) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$z->{'id'},
|
||||
$zcan{$z->{'host'}} || $zcan{$z->{'id'}} ? "selected" : "",
|
||||
$z->{'host'} ;
|
||||
|
@ -376,28 +376,28 @@ if ($_[3] == 2) {
|
||||
$found = !$_[1];
|
||||
}
|
||||
elsif ($_[3] == 1) {
|
||||
printf "<option value=- %s>%s\n",
|
||||
printf "<option value=- %s>%s</option>\n",
|
||||
$_[1] eq '-' ? "selected" : "", "<$text{'list_any'}>";
|
||||
$found = !$_[1] || $_[1] eq '-';
|
||||
}
|
||||
elsif ($_[3] == 0) {
|
||||
printf "<option value=all %s>%s\n",
|
||||
printf "<option value=all %s>%s</option>\n",
|
||||
$_[1] eq 'all' ? "selected" : "", "<$text{'list_any'}>";
|
||||
printf "<option value=\$FW %s>%s\n",
|
||||
printf "<option value=\$FW %s>%s</option>\n",
|
||||
&is_fw($_[1]) ? "selected" : "", "<$text{'list_fw'}>";
|
||||
$found = !$_[1] || $_[1] eq 'all' || &is_fw($_[1]);
|
||||
}
|
||||
foreach $z (@ztable) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$z->[0], $_[1] eq $z->[0] ? "selected" : "", &convert_zone($z->[0]);
|
||||
$found++ if ($_[1] eq $z->[0]);
|
||||
}
|
||||
if ($_[2]) {
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
}
|
||||
else {
|
||||
print "<option value=$_[1] selected>$_[1]\n" if (!$found);
|
||||
print "<option value=$_[1] selected>$_[1]</option>\n" if (!$found);
|
||||
}
|
||||
print "</select>\n";
|
||||
return $found;
|
||||
@ -410,11 +410,11 @@ local @itable = &read_table_file("interfaces", \&standard_parser);
|
||||
print "<select name=$_[0]>\n";
|
||||
local $found = !$_[1];
|
||||
foreach $i (@itable) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$i->[1], $_[1] eq $i->[1] ? "selected" : "", $i->[1];
|
||||
$found++ if ($_[1] eq $i->[1]);
|
||||
}
|
||||
print "<option value=$_[1] selected>$_[1]\n" if (!$found);
|
||||
print "<option value=$_[1] selected>$_[1]</option>\n" if (!$found);
|
||||
print "</select>\n";
|
||||
}
|
||||
|
||||
@ -713,27 +713,27 @@ print "<tr> <td><b>$text{'policy_2'}</b></td>\n";
|
||||
print "<td><select name=policy>\n";
|
||||
$found = !$_[2];
|
||||
foreach $p (@policy_list) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, lc($p) eq lc($_[2]) ? "selected" : "", $p;
|
||||
$found++ if (lc($p) eq lc($_[2]));
|
||||
}
|
||||
print "<option value=$_[2] selected>$_[2]\n" if (!$found);
|
||||
print "<option value=$_[2] selected>$_[2]</option>\n" if (!$found);
|
||||
print "</select></td>\n";
|
||||
|
||||
print "<td><b>$text{'policy_3'}</b></td>\n";
|
||||
print "<td><select name=log>\n";
|
||||
printf "<option value=- %s>%s\n",
|
||||
printf "<option value=- %s>%s</option>\n",
|
||||
$_[3] eq '-' || !$_[3] ? "selected" : "", "<$text{'policy_nolog'}>";
|
||||
printf "<option value=ULOG %s>%s\n",
|
||||
printf "<option value=ULOG %s>%s</option>\n",
|
||||
$_[3] eq 'ULOG' ? "selected" : "", "<$text{'policy_ulog'}>";
|
||||
$found = !$_[3] || $_[3] eq '-' || $_[3] eq 'ULOG';
|
||||
&foreign_require("syslog", "syslog-lib.pl");
|
||||
foreach $l (&syslog::list_priorities()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$l, $_[3] eq $l ? "selected" : "", $l;
|
||||
$found++ if ($_[3] eq $l);
|
||||
}
|
||||
print "<option value=$_[3] selected>$_[3]\n" if (!$found);
|
||||
print "<option value=$_[3] selected>$_[3]</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
local ($l, $b) = $_[4] =~ /(\d+):(\d+)/ ? ($1, $2) : ( );
|
||||
@ -825,27 +825,27 @@ foreach $a ((sort { $a cmp $b } @rules_actions),
|
||||
&list_standard_actions(),
|
||||
(&version_atleast(3) ? ( "-------- Macros --------",
|
||||
&list_standard_macros() ) : ( ) )) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$a, $action eq $a ? "selected" : "", $a;
|
||||
$found++ if ($action eq $a);
|
||||
}
|
||||
print "<option value=$action selected>$action\n" if (!$found);
|
||||
print "<option value=$action selected>$action</option>\n" if (!$found);
|
||||
print "</select>\n";
|
||||
|
||||
# Logging level
|
||||
print "<b>$text{'rules_log'}</b> <select name=log>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
!$log ? "selected" : "", "<$text{'rules_nolog'}>";
|
||||
printf "<option value=ULOG %s>%s\n",
|
||||
printf "<option value=ULOG %s>%s</option>\n",
|
||||
$log eq 'ULOG' ? "selected" : "", "<$text{'policy_ulog'}>";
|
||||
$found = !$log || $log eq '-' || $log eq 'ULOG';
|
||||
&foreign_require("syslog", "syslog-lib.pl");
|
||||
foreach $l (&syslog::list_priorities()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$l, $log eq $l ? "selected" : "", $l;
|
||||
$found++ if ($log eq $l);
|
||||
}
|
||||
print "<option value=$log selected>$log\n" if (!$found);
|
||||
print "<option value=$log selected>$log</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
if (&version_atleast(3)) {
|
||||
@ -890,13 +890,13 @@ print "<tr> <td><b>$text{'rules_3'}</b></td>\n";
|
||||
print "<td colspan=3><select name=proto>\n";
|
||||
$found = !$_[3];
|
||||
foreach $p (@rules_protos) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, $p eq $_[3] ? "selected" : "",
|
||||
$p eq 'all' ? "<$text{'list_any'}>" :
|
||||
$p eq 'related' ? "<$text{'rules_related'}>" : uc($p);
|
||||
$found++ if ($p eq $_[3]);
|
||||
}
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=pother size=5 value='%s'></td> </tr>\n",
|
||||
@ -1061,11 +1061,11 @@ print "<tr> <td><b>$text{'tos_2'}</b></td>\n";
|
||||
print "<td><select name=proto>\n";
|
||||
$found = !$_[2];
|
||||
foreach $p (@tos_protos) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, $p eq $_[2] ? "selected" : "", uc($p);
|
||||
$found++ if ($p eq $_[2]);
|
||||
}
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=pother size=5 value='%s'></td> </tr>\n",
|
||||
@ -1091,11 +1091,11 @@ print "<tr> <td><b>$text{'tos_5'}</b></td>\n";
|
||||
print "<td><select name=tos>\n";
|
||||
$found = !$_[5];
|
||||
foreach $t (sort { $a <=> $b } keys %tos_map) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $_[5] == $t ? "selected" : "", $tos_map{$t};
|
||||
$found++ if ($_[5] == $t);
|
||||
}
|
||||
print "<option value=$_[5] selected>$_[5]\n" if (!$found);
|
||||
print "<option value=$_[5] selected>$_[5]</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
print "<tr> <td><b>$text{'tos_6'}</b></td>\n";
|
||||
@ -1430,12 +1430,12 @@ foreach $tt ('ipsec', 'ipsecnat',
|
||||
: ( )),
|
||||
'ip', 'gre', 'pptpclient', 'pptpserver', 'generic',
|
||||
(&version_atleast(1, 3, 14) ? ( 'openvpn' ) : ( )) ) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$tt, $ttype eq $tt ? "selected" : "",
|
||||
$text{'tunnels_'.$tt.'_l'} || $text{'tunnels_'.$tt};
|
||||
$found++ if ($ttype eq $tt);
|
||||
}
|
||||
print "<option value=$ttype selected>",uc($ttype),"\n" if (!$found);
|
||||
print "<option value=$ttype selected>",uc($ttype),"</option>\n" if (!$found);
|
||||
print "</select>\n";
|
||||
print "<input name=tport size=10 value='$tport'>\n";
|
||||
print "</td>\n";
|
||||
@ -1564,12 +1564,12 @@ print "<tr> <td><b>$text{'blacklist_proto'}</b></td>\n";
|
||||
print "<td colspan=3><select name=proto>\n";
|
||||
$found = !$_[1];
|
||||
foreach $p (@blacklist_protos) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$p, $p eq $_[1] ? "selected" : "",
|
||||
$p eq '' ? "<$text{'list_any'}>" : uc($p);
|
||||
$found++ if ($p eq $_[1]);
|
||||
}
|
||||
printf "<option value='*' %s>%s\n",
|
||||
printf "<option value='*' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=pother size=5 value='%s'></td> </tr>\n",
|
||||
|
@ -366,28 +366,28 @@ if ($_[3] == 2) {
|
||||
$found = !$_[1];
|
||||
}
|
||||
elsif ($_[3] == 1) {
|
||||
printf "<option value=- %s>%s\n",
|
||||
printf "<option value=- %s>%s</option>\n",
|
||||
$_[1] eq '-' ? "selected" : "", "<$text{'list_any'}>";
|
||||
$found = !$_[1] || $_[1] eq '-';
|
||||
}
|
||||
elsif ($_[3] == 0) {
|
||||
printf "<option value=all %s>%s\n",
|
||||
printf "<option value=all %s>%s</option>\n",
|
||||
$_[1] eq 'all' ? "selected" : "", "<$text{'list_any'}>";
|
||||
printf "<option value=\$FW %s>%s\n",
|
||||
printf "<option value=\$FW %s>%s</option>\n",
|
||||
&is_fw($_[1]) ? "selected" : "", "<$text{'list_fw'}>";
|
||||
$found = !$_[1] || $_[1] eq 'all' || &is_fw($_[1]);
|
||||
}
|
||||
foreach $z (@ztable) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$z->[0], $_[1] eq $z->[0] ? "selected" : "", &convert_zone($z->[0]);
|
||||
$found++ if ($_[1] eq $z->[0]);
|
||||
}
|
||||
if ($_[2]) {
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
}
|
||||
else {
|
||||
print "<option value=$_[1] selected>$_[1]\n" if (!$found);
|
||||
print "<option value=$_[1] selected>$_[1]</option>\n" if (!$found);
|
||||
}
|
||||
print "</select>\n";
|
||||
return $found;
|
||||
@ -400,11 +400,11 @@ local @itable = &read_table_file("interfaces", \&standard_parser);
|
||||
print "<select name=$_[0]>\n";
|
||||
local $found = !$_[1];
|
||||
foreach $i (@itable) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$i->[1], $_[1] eq $i->[1] ? "selected" : "", $i->[1];
|
||||
$found++ if ($_[1] eq $i->[1]);
|
||||
}
|
||||
print "<option value=$_[1] selected>$_[1]\n" if (!$found);
|
||||
print "<option value=$_[1] selected>$_[1]</option>\n" if (!$found);
|
||||
print "</select>\n";
|
||||
}
|
||||
|
||||
@ -672,27 +672,27 @@ print "<tr> <td><b>$text{'policy_2'}</b></td>\n";
|
||||
print "<td><select name=policy>\n";
|
||||
$found = !$_[2];
|
||||
foreach $p (@policy_list) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, lc($p) eq lc($_[2]) ? "selected" : "", $p;
|
||||
$found++ if (lc($p) eq lc($_[2]));
|
||||
}
|
||||
print "<option value=$_[2] selected>$_[2]\n" if (!$found);
|
||||
print "<option value=$_[2] selected>$_[2]</option>\n" if (!$found);
|
||||
print "</select></td>\n";
|
||||
|
||||
print "<td><b>$text{'policy_3'}</b></td>\n";
|
||||
print "<td><select name=log>\n";
|
||||
printf "<option value=- %s>%s\n",
|
||||
printf "<option value=- %s>%s</option>\n",
|
||||
$_[3] eq '-' || !$_[3] ? "selected" : "", "<$text{'policy_nolog'}>";
|
||||
#printf "<option value=ULOG %s>%s\n",
|
||||
#printf "<option value=ULOG %s>%s</option>\n",
|
||||
# $_[3] eq 'ULOG' ? "selected" : "", "<$text{'policy_ulog'}>";
|
||||
#$found = !$_[3] || $_[3] eq '-' || $_[3] eq 'ULOG';
|
||||
&foreign_require("syslog", "syslog-lib.pl");
|
||||
foreach $l (&syslog::list_priorities()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$l, $_[3] eq $l ? "selected" : "", $l;
|
||||
$found++ if ($_[3] eq $l);
|
||||
}
|
||||
print "<option value=$_[3] selected>$_[3]\n" if (!$found);
|
||||
print "<option value=$_[3] selected>$_[3]</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
local ($l, $b) = $_[4] =~ /(\d+):(\d+)/ ? ($1, $2) : ( );
|
||||
@ -772,27 +772,27 @@ foreach $a ((sort { $a cmp $b } @rules_actions),
|
||||
&list_standard_actions(),
|
||||
(&version_atleast(3) ? ( "-------- Macros --------",
|
||||
&list_standard_macros() ) : ( ) )) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$a, $action eq $a ? "selected" : "", $a;
|
||||
$found++ if ($action eq $a);
|
||||
}
|
||||
print "<option value=$action selected>$action\n" if (!$found);
|
||||
print "<option value=$action selected>$action</option>\n" if (!$found);
|
||||
print "</select>\n";
|
||||
|
||||
# Logging level
|
||||
print "<b>$text{'rules_log'}</b> <select name=log>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
!$log ? "selected" : "", "<$text{'rules_nolog'}>";
|
||||
printf "<option value=ULOG %s>%s\n",
|
||||
printf "<option value=ULOG %s>%s</option>\n",
|
||||
$log eq 'ULOG' ? "selected" : "", "<$text{'policy_ulog'}>";
|
||||
$found = !$log || $log eq '-' || $log eq 'ULOG';
|
||||
&foreign_require("syslog", "syslog-lib.pl");
|
||||
foreach $l (&syslog::list_priorities()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$l, $log eq $l ? "selected" : "", $l;
|
||||
$found++ if ($log eq $l);
|
||||
}
|
||||
print "<option value=$log selected>$log\n" if (!$found);
|
||||
print "<option value=$log selected>$log</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
if (&version_atleast(3)) {
|
||||
@ -837,13 +837,13 @@ print "<tr> <td><b>$text{'rules_3'}</b></td>\n";
|
||||
print "<td colspan=3><select name=proto>\n";
|
||||
$found = !$_[3];
|
||||
foreach $p (@rules_protos) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, $p eq $_[3] ? "selected" : "",
|
||||
$p eq 'all' ? "<$text{'list_any'}>" :
|
||||
$p eq 'related' ? "<$text{'rules_related'}>" : uc($p);
|
||||
$found++ if ($p eq $_[3]);
|
||||
}
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=pother size=5 value='%s'></td> </tr>\n",
|
||||
@ -1008,11 +1008,11 @@ print "<tr> <td><b>$text{'tos_2'}</b></td>\n";
|
||||
print "<td><select name=proto>\n";
|
||||
$found = !$_[2];
|
||||
foreach $p (@tos_protos) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$p, $p eq $_[2] ? "selected" : "", uc($p);
|
||||
$found++ if ($p eq $_[2]);
|
||||
}
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=pother size=5 value='%s'></td> </tr>\n",
|
||||
@ -1038,11 +1038,11 @@ print "<tr> <td><b>$text{'tos_5'}</b></td>\n";
|
||||
print "<td><select name=tos>\n";
|
||||
$found = !$_[5];
|
||||
foreach $t (sort { $a <=> $b } keys %tos_map) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $_[5] == $t ? "selected" : "", $tos_map{$t};
|
||||
$found++ if ($_[5] == $t);
|
||||
}
|
||||
print "<option value=$_[5] selected>$_[5]\n" if (!$found);
|
||||
print "<option value=$_[5] selected>$_[5]</option>\n" if (!$found);
|
||||
print "</select></td> </tr>\n";
|
||||
|
||||
print "<tr> <td><b>$text{'tos_6'}</b></td>\n";
|
||||
@ -1204,12 +1204,12 @@ if ($ttype =~ s/^(openvpn|openvpnserver|openvpnclient|generic):(.*)$/$1/) {
|
||||
foreach $tt ('ipsec', 'ipsecnat',
|
||||
'ipsec:ah',
|
||||
'gre', 'l2tp', 'openvpn', 'openvpnclient', 'openvpnserver', 'generic') {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$tt, $ttype eq $tt ? "selected" : "",
|
||||
$text{'tunnels_'.$tt.'_l'} || $text{'tunnels_'.$tt};
|
||||
$found++ if ($ttype eq $tt);
|
||||
}
|
||||
print "<option value=$ttype selected>",uc($ttype),"\n" if (!$found);
|
||||
print "<option value=$ttype selected>",uc($ttype),"</option>\n" if (!$found);
|
||||
print "</select>\n";
|
||||
print "<input name=tport size=10 value='$tport'>\n";
|
||||
print "</td>\n";
|
||||
@ -1334,12 +1334,12 @@ print "<tr> <td><b>$text{'blacklist_proto'}</b></td>\n";
|
||||
print "<td colspan=3><select name=proto>\n";
|
||||
$found = !$_[1];
|
||||
foreach $p (@blacklist_protos) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$p, $p eq $_[1] ? "selected" : "",
|
||||
$p eq '' ? "<$text{'list_any'}>" : uc($p);
|
||||
$found++ if ($p eq $_[1]);
|
||||
}
|
||||
printf "<option value='*' %s>%s\n",
|
||||
printf "<option value='*' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'list_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=pother size=5 value='%s'></td> </tr>\n",
|
||||
|
@ -11,7 +11,7 @@ print "<td><select name=avail rows=6 multiple>\n";
|
||||
local %avail = map { $_, 1 } split(/,/, $_[0]->{'avail'});
|
||||
foreach $a ('white', 'score', 'report', 'user', 'header', 'setup', 'procmail',
|
||||
'db', 'awl') {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$a, $avail{$a} ? "selected" : "", $text{$a."_title"};
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -170,7 +170,7 @@ if ($access{'edit'}) {
|
||||
print "<input type=submit value='$text{'index_add'}'> ",
|
||||
"<select name=type>\n";
|
||||
foreach $h (sort { $a->[1] cmp $b->[1] } &list_handlers()) {
|
||||
printf "<option value=%s>%s\n",
|
||||
printf "<option value=%s>%s</option>\n",
|
||||
$h->[0], $h->[1] || $h->[0];
|
||||
}
|
||||
print "</select></form>\n";
|
||||
|
@ -84,7 +84,7 @@ print "<td><b>$text{'mailserver_timeout'}</b></td>\n";
|
||||
print "<td><input name=timeout size=5 value='$_[0]->{'timeout'}'>\n";
|
||||
print "<select name=units>\n";
|
||||
for($i=0; defined($text{"mailserver_units_$i"}); $i++) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$i, $_[0]->{'units'} == $i ? "selected" : "",
|
||||
$text{"mailserver_units_$i"};
|
||||
}
|
||||
|
@ -44,8 +44,8 @@ if (!$in{'new'}) {
|
||||
elsif ($has_inetd && $has_xinetd) {
|
||||
print "<td><b>$text{'edit_type'}</b></td>\n";
|
||||
print "<td><select name=type>\n";
|
||||
print "<option selected>xinetd\n";
|
||||
print "<option>inetd\n";
|
||||
print "<option selected>xinetd</option>\n";
|
||||
print "<option>inetd</option>\n";
|
||||
print "</select></td>\n";
|
||||
}
|
||||
print "</tr>\n";
|
||||
|
@ -8,7 +8,7 @@ sub acl_security_form
|
||||
print "<tr> <td valign=top><b>$text{'acl_icons'}</b></td>\n";
|
||||
print "<td colspan=3><select name=icons multiple size=10>\n";
|
||||
foreach $i (&get_icons()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$i, $_[0]->{$i} ? "selected" : "", $text{"${i}_title"};
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -21,7 +21,7 @@ printf "<input type=radio name=mods_def value=0 %s> %s<br>\n",
|
||||
local %mods = map { $_, 1 } split(/\s+/, $_[0]->{'mods'});
|
||||
print "<select name=mods multiple size=10>\n";
|
||||
foreach $m (&list_modules()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$m->{'dir'}, $mods{$m->{'dir'}} ? "selected" : "", $m->{'desc'};
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -44,7 +44,7 @@ sub cats {
|
||||
$cats{$_} = $catnames{$_};
|
||||
}
|
||||
foreach $c (sort { $cats{$a} cmp $cats{$b} } keys %cats) {
|
||||
$cats .= sprintf "<option value='%s' %s>%s\n",
|
||||
$cats .= sprintf "<option value='%s' %s>%s</option>\n",
|
||||
$c, $_[1] eq $c ? 'selected' : '', $cats{$c};
|
||||
}
|
||||
$cats = qq(<select name="$_[0]">$cats\n</select>\n);
|
||||
|
@ -38,7 +38,7 @@ print "<tr> <td nowrap><b>$text{'mods_cname'}</b></td>\n";
|
||||
print "<td><select name=mod>\n";
|
||||
foreach $m (@mlist) {
|
||||
if (!$m->{'clone'}) {
|
||||
printf "<option value='%s'>%s\n",
|
||||
printf "<option value='%s'>%s</option>\n",
|
||||
$m->{'dir'}, $m->{'desc'};
|
||||
}
|
||||
}
|
||||
@ -48,7 +48,7 @@ print "<tr> <td nowrap><b>$text{'mods_cnew'}</b></td>\n";
|
||||
print "<td><input name=desc size=30></td> </tr>\n";
|
||||
print "<tr> <td nowrap><b>$text{'mods_ccat'}</b></td>\n";
|
||||
print "<td><select name=cat>\n";
|
||||
print "<option value=* selected>$text{'mods_csame'}\n";
|
||||
print "<option value=* selected>$text{'mods_csame'}</option>\n";
|
||||
&get_usermin_miniserv_config(\%miniserv);
|
||||
&read_file("$miniserv{'root'}/lang/en", \%utext);
|
||||
&read_file("$miniserv{'root'}/ulang/en", \%utext);
|
||||
@ -62,7 +62,7 @@ foreach $t (keys %catnames) {
|
||||
$cats{$t} = $catnames{$t};
|
||||
}
|
||||
foreach $c (sort { $cats{$a} cmp $cats{$b} } keys %cats) {
|
||||
print "<option value=$c>$cats{$c}\n";
|
||||
print "<option value=$c>$cats{$c}</option>\n";
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
print "</table></td></tr> </table>\n";
|
||||
@ -88,7 +88,7 @@ foreach $m (@mlist) {
|
||||
$home ? "" :
|
||||
sprintf "(%d/%d/%d)",
|
||||
$tm[3], $tm[4]+1, $tm[5]+1900;
|
||||
printf "<option value='%s'>%s %s\n",
|
||||
printf "<option value='%s'>%s %s</option>\n",
|
||||
$m->{'dir'}, $m->{'desc'}, $vstr;
|
||||
}
|
||||
}
|
||||
|
@ -14,7 +14,7 @@ if (@themes) {
|
||||
print "<form action=change_theme.cgi>\n";
|
||||
print "<b>$text{'themes_sel'}</b> <select name=theme>\n";
|
||||
foreach $t ( { 'desc' => $text{'themes_default'} }, @themes) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$t->{'dir'},
|
||||
$uconfig{'theme'} eq $t->{'dir'} ? 'selected' : '',
|
||||
$t->{'desc'};
|
||||
@ -52,7 +52,7 @@ if (@themes) {
|
||||
print "<b>$text{'themes_delok'}</b>\n";
|
||||
print "<select name=mod>\n";
|
||||
foreach $t (@themes) {
|
||||
printf "<option value=%s>%s\n",
|
||||
printf "<option value=%s>%s</option>\n",
|
||||
$t->{'dir'}, $t->{'desc'};
|
||||
}
|
||||
print "</select>\n";
|
||||
|
@ -31,13 +31,13 @@ foreach $t (sort { "$a$b" =~ /^ttyS(\d+)ttyS(\d+)$/ ? $1 <=> $2 : 0 }
|
||||
readdir(DEV)) {
|
||||
if ($t =~ /^ttyS(\d+)$/) {
|
||||
local $f = $init->{'tty'} eq $t || $init->{'tty'} eq "/dev/$t";
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$t, $f ? "selected" : "", &text('vgetty_ts', $1+1);
|
||||
$found++ if ($f);
|
||||
}
|
||||
}
|
||||
closedir(DEV);
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$found ? "" : "selected", $text{'vgetty_other'};
|
||||
print "</select>\n";
|
||||
printf "<input name=other size=20 value='%s'> %s</td> </tr>\n",
|
||||
|
@ -63,7 +63,7 @@ print "<input type=submit value='$text{'messages_upload'}'>\n";
|
||||
print "<input name=wav type=file>\n";
|
||||
print "$text{'messages_fmt'} <select name=format>\n";
|
||||
foreach $f (&list_rmd_formats()) {
|
||||
printf "<option value='%s' %s>%s\n",
|
||||
printf "<option value='%s' %s>%s</option>\n",
|
||||
$f->{'index'},
|
||||
$f->{'index'} == $config{'format'} ? "selected" : "",
|
||||
$f->{'desc'};
|
||||
|
@ -97,7 +97,7 @@ local ($i, $rv);
|
||||
for($i=0; $i<3; $i++) {
|
||||
$rv .= "<select name=$_[1]_$i>\n";
|
||||
foreach $m (@modes) {
|
||||
$rv .= sprintf "<option value='%s' %s>%s\n",
|
||||
$rv .= sprintf "<option value='%s' %s>%s</option>\n",
|
||||
$m, $am[$i] eq $m ? "selected" : "", $text{"vgetty_ans_$m"};
|
||||
}
|
||||
$rv .= "</select> ";
|
||||
|
@ -51,7 +51,7 @@ print "<tr> <td><b>$text{'edit_type'}</b></td> <td>\n";
|
||||
if ($in{'new'}) {
|
||||
print "<select name=type>\n";
|
||||
for($i=1; defined($t = $text{'index_type'.$i}); $i++) {
|
||||
print "<option value=$i>$t\n";
|
||||
print "<option value=$i>$t</option>\n";
|
||||
}
|
||||
print "</select>\n";
|
||||
}
|
||||
|
@ -300,7 +300,7 @@ foreach my $arr ("mins", "hours", "days", "months", "weekdays") {
|
||||
foreach my $v (@sec) {
|
||||
if ($v =~ /^(.*)=(.*)$/) { $disp = $1; $code = $2; }
|
||||
else { $disp = $code = $v; }
|
||||
$rv .= sprintf "<option value=\"$code\" %s>$disp\n",
|
||||
$rv .= sprintf "<option value=\"$code\" %s>$disp</option>\n",
|
||||
$inuse{$code} ? "selected" : "";
|
||||
}
|
||||
$rv .= "</select></td>\n";
|
||||
|
@ -16,7 +16,7 @@ local %gotmod = map { $_, 1 } split(/\s+/, $_[0]->{'mods'});
|
||||
print "<select name=mods multiple size=10 width=400>\n";
|
||||
my $m;
|
||||
foreach $m (sort { $a->{'desc'} cmp $b->{'desc'} } &get_all_module_infos()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$m->{'dir'}, $gotmod{$m->{'dir'}} ? "selected" : "",
|
||||
$m->{'desc'};
|
||||
}
|
||||
@ -32,7 +32,7 @@ local %gotuser = map { $_, 1 } split(/\s+/, $_[0]->{'users'});
|
||||
print "<select name=users multiple size=10 width=400>\n";
|
||||
my $u;
|
||||
foreach $u (sort { $a->{'name'} cmp $b->{'name'} } &acl::list_users()) {
|
||||
printf "<option value=%s %s>%s\n",
|
||||
printf "<option value=%s %s>%s</option>\n",
|
||||
$u->{'name'}, $gotuser{$u->{'name'}} ? "selected" : "",
|
||||
$u->{'name'};
|
||||
}
|
||||
|
@ -42,9 +42,9 @@ $i = 0;
|
||||
foreach $l (@limit) {
|
||||
print "<tr $cb>\n";
|
||||
print "<td><select name=lclass_$i>\n";
|
||||
printf "<option value='' %s> \n", $l->[0] ? '' : 'checked';
|
||||
printf "<option value='' %s> </option>\n", $l->[0] ? '' : 'checked';
|
||||
foreach $c (@class) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$l->[0] eq $c->[0] ? 'selected' : '', $c->[0];
|
||||
}
|
||||
print "</select></td>\n";
|
||||
@ -87,22 +87,22 @@ foreach $l (@fblimit) {
|
||||
splice(@$f, 0, 0, '0') if ($f->[0] ne 'raw');
|
||||
print "<tr $cb>\n";
|
||||
print "<td><select name=fblimit_$i>\n";
|
||||
printf "<option value='' %s> \n",
|
||||
printf "<option value='' %s> </option>\n",
|
||||
$l->{'name'} ? '' : 'selected';
|
||||
printf "<option value=file-limit %s>%s\n",
|
||||
printf "<option value=file-limit %s>%s</option>\n",
|
||||
$l->{'name'} eq 'file-limit' ? 'selected' : '',
|
||||
$text{'acl_flimit'};
|
||||
printf "<option value=byte-limit %s>%s\n",
|
||||
printf "<option value=byte-limit %s>%s</option>\n",
|
||||
$l->{'name'} eq 'byte-limit' ? 'selected' : '',
|
||||
$text{'acl_blimit'};
|
||||
print "</select></td>\n";
|
||||
|
||||
print "<td><select name=fbinout_$i>\n";
|
||||
printf "<option value=total %s>%s\n",
|
||||
printf "<option value=total %s>%s</option>\n",
|
||||
$f->[1] eq 'total' ? 'selected' : '', $text{'acl_total'};
|
||||
printf "<option value=in %s>%s\n",
|
||||
printf "<option value=in %s>%s</option>\n",
|
||||
$f->[1] eq 'in' ? 'selected' : '', $text{'acl_in'};
|
||||
printf "<option value=out %s>%s\n",
|
||||
printf "<option value=out %s>%s</option>\n",
|
||||
$f->[1] eq 'out' ? 'selected' : '', $text{'acl_out'};
|
||||
print "</select></td>\n";
|
||||
|
||||
@ -114,10 +114,10 @@ foreach $l (@fblimit) {
|
||||
print "<td><input name=fbcount_$i size=10 value='$f->[2]'></td>\n";
|
||||
|
||||
print "<td><select name=fbclass_$i>\n";
|
||||
printf "<option value='' %s> %s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$f->[3] ? '' : 'selected', $text{'acl_all'};
|
||||
foreach $c (@class) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$f->[3] eq $c->[0] ? 'selected' : '', $c->[0];
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
@ -29,10 +29,10 @@ foreach $r (@root) {
|
||||
printf "<td><input name=dir_$i size=35 value='%s'> %s</td>\n",
|
||||
$r->[0], &file_chooser_button("dir_$i", 1);
|
||||
print "<td><select name=class_$i>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$r->[1] ? '' : 'selected', $text{'anon_any'};
|
||||
foreach $c (@class) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$r->[1] eq $c->[0] ? 'selected' : '', $c->[0];
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -94,12 +94,12 @@ printf "<input type=radio name=passwd_def value=0 %s>\n",
|
||||
$p ? 'checked' : '';
|
||||
print "<select name=level>\n";
|
||||
foreach $l ('none', 'trivial', 'rfc822') {
|
||||
printf "<option %s value='%s'>%s\n",
|
||||
printf "<option %s value='%s'>%s</option>\n",
|
||||
$p->[0] eq $l ? 'selected' : '', $l, $text{"anon_$l"};
|
||||
}
|
||||
print "</select> <select name=action>\n";
|
||||
foreach $a ('enforce', 'warn') {
|
||||
printf "<option %s value='%s'>%s\n",
|
||||
printf "<option %s value='%s'>%s</option>\n",
|
||||
$p->[1] eq $a ? 'selected' : '', $a, $text{"anon_$a"};
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -47,10 +47,10 @@ foreach $n (@nice) {
|
||||
print "<tr $cb>\n";
|
||||
print "<td><input name=ndelta_$i size=5 value='$n->[0]'></td>\n";
|
||||
print "<td><select name=nclass_$i>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$n->[1] ? '' : 'checked', $text{'misc_all'};
|
||||
foreach $c (@class) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$n->[1] eq $c->[0] ? 'selected' : '', $c->[0];
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
@ -70,10 +70,10 @@ foreach $u (@umask) {
|
||||
print "<tr $cb>\n";
|
||||
print "<td><input name=umask_$i size=5 value='$u->[0]'></td>\n";
|
||||
print "<td><select name=uclass_$i>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$u->[1] ? '' : 'checked', $text{'misc_all'};
|
||||
foreach $c (@class) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$u->[1] eq $c->[0] ? 'selected' : '', $c->[0];
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -24,10 +24,10 @@ foreach $t (@tcp) {
|
||||
print "<tr $cb>\n";
|
||||
print "<td><input name=tsize_$i size=5 value='$t->[0]'></td>\n";
|
||||
print "<td><select name=tclass_$i>\n";
|
||||
printf "<option value='' %s>%s\n",
|
||||
printf "<option value='' %s>%s</option>\n",
|
||||
$t->[1] ? '' : 'checked', $text{'net_tall'};
|
||||
foreach $c (@class) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$t->[1] eq $c->[0] ? 'selected' : '', $c->[0];
|
||||
}
|
||||
print "</select></td> </tr>\n";
|
||||
|
@ -31,9 +31,9 @@ foreach $p (@perms) {
|
||||
print "<tr $cb>\n";
|
||||
|
||||
print "<td><select name=type_$i>\n";
|
||||
printf "<option %s>\n", $p->{'name'} ? '' : 'checked';
|
||||
printf "<option %s></option>\n", $p->{'name'} ? '' : 'checked';
|
||||
foreach $t (@permtypes) {
|
||||
printf "<option %s>%s\n",
|
||||
printf "<option %s>%s</option>\n",
|
||||
$p->{'name'} eq $t ? 'selected' : '', $t;
|
||||
}
|
||||
print "</select></td>\n";
|
||||
|
Loading…
x
Reference in New Issue
Block a user