mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-27 19:23:24 +02:00
firewall: Fix collapsing the NAT menu.
Also removing a lot of redundant HTML code and invalid attributes.
This commit is contained in:
@@ -137,13 +137,13 @@ print<<END;
|
|||||||
update_protocol();
|
update_protocol();
|
||||||
|
|
||||||
// When nat not used, hide it
|
// When nat not used, hide it
|
||||||
if (! \$("#nat").attr("checked")) {
|
if (! \$("#USE_NAT").attr("checked")) {
|
||||||
\$("#natpart").hide();
|
\$("#NAT").hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Show NAT area when "use nat" checkbox is clicked
|
// Show NAT area when "use nat" checkbox is clicked
|
||||||
\$("#nat").change(function() {
|
\$("#USE_NAT").change(function() {
|
||||||
\$("#natpart").toggle();
|
\$("#NAT").toggle();
|
||||||
});
|
});
|
||||||
|
|
||||||
// Time constraints
|
// Time constraints
|
||||||
@@ -1656,11 +1656,18 @@ END
|
|||||||
#---SNAT / DNAT ------------------------------------------------
|
#---SNAT / DNAT ------------------------------------------------
|
||||||
&Header::openbox('100%', 'left', 'NAT');
|
&Header::openbox('100%', 'left', 'NAT');
|
||||||
print<<END;
|
print<<END;
|
||||||
<div id="nat"><table width='100%' border='0'>
|
<label>
|
||||||
<tr><td width='1%'><input type='checkbox' name='USE_NAT' id='USE_NAT' value='ON' $checked{'USE_NAT'}{'ON'} ></td><td width='15%'>$Lang::tr{'fwdfw use nat'}</td><td colspan='5'></td></tr></table></div>
|
<input type='checkbox' name='USE_NAT' id='USE_NAT' $checked{'USE_NAT'}{'ON'}>
|
||||||
<div id="natpart" class="noscript">
|
$Lang::tr{'fwdfw use nat'}
|
||||||
<table width='100%' border='0'><tr>
|
</label>
|
||||||
<tr><td colspan='2'></td><td width='1%'><input type='radio' name='nat' id='dnat' value='dnat' checked ></td><td width='50%'>$Lang::tr{'fwdfw dnat'}</td>
|
<div id="NAT">
|
||||||
|
<table width='100%' border='0'>
|
||||||
|
<tr>
|
||||||
|
<td colspan='2'></td>
|
||||||
|
<td width='1%'>
|
||||||
|
<input type='radio' name='nat' id='dnat' value='dnat' checked>
|
||||||
|
</td>
|
||||||
|
<td width='50%'>$Lang::tr{'fwdfw dnat'}</td>
|
||||||
END
|
END
|
||||||
print"<td width='8%'>Firewall: </td><td width='20%' align='right'><select name='dnat' style='width:140px;'>";
|
print"<td width='8%'>Firewall: </td><td width='20%' align='right'><select name='dnat' style='width:140px;'>";
|
||||||
print "<option value='ALL' $selected{'dnat'}{$Lang::tr{'all'}}>$Lang::tr{'all'}</option>";
|
print "<option value='ALL' $selected{'dnat'}{$Lang::tr{'all'}}>$Lang::tr{'all'}</option>";
|
||||||
@@ -1690,7 +1697,7 @@ END
|
|||||||
print ">$network</option>";
|
print ">$network</option>";
|
||||||
}
|
}
|
||||||
print"</select></td></tr></table>";
|
print"</select></td></tr></table>";
|
||||||
print"</div><br><hr>";
|
print"</div>";
|
||||||
&Header::closebox();
|
&Header::closebox();
|
||||||
#---TARGET------------------------------------------------------
|
#---TARGET------------------------------------------------------
|
||||||
&Header::openbox('100%', 'left', $Lang::tr{'fwdfw target'});
|
&Header::openbox('100%', 'left', $Lang::tr{'fwdfw target'});
|
||||||
|
|||||||
Reference in New Issue
Block a user