Fix Javascript errors. Thanks JSLint!!

This commit is contained in:
Bill Marquette 2007-10-19 21:17:17 +00:00
parent e6056acc60
commit 916ec736fc
2 changed files with 5 additions and 5 deletions

View File

@ -194,7 +194,7 @@ function type_change(enable_change) {
//clearcombo();
document.iform.gatewayip.disabled = 1;
document.iform.ipaddr.style.display = "block";
document.iform.interface.style.display = "none";
document.iform.iface.style.display = "none";
document.iform.serversSelect.clear;
document.iform.monitorip.disabled = 1;
var monitorIpNote = document.getElementById("monitorIpNote");
@ -220,7 +220,7 @@ function type_change(enable_change) {
//clearcombo();
document.iform.gatewayip.disabled = 0;
document.iform.ipaddr.style.display = "none";
document.iform.interface.style.display = "block";
document.iform.iface.style.display = "block";
document.iform.monitorip.disabled = 0;
document.iform.monitorip.value = "";
var monitorIpNote = document.getElementById("monitorIpNote");
@ -344,7 +344,7 @@ function clearcombo(){
<td width="22%" valign="top" class="vncellreq"><div id="interfacename_text"></div></td>
<td width="78%" class="vtable" colspan="2">
<input name="ipaddr" type="text" size="16" style="float: left;">
<select id="interface" name="interface" style="float: left; display: none;">
<select id="iface" name="interface" style="float: left; display: none;">
<?php
$interfaces = array('wan' => 'WAN', 'lan' => 'LAN');
for ($i = 1; isset($config['interfaces']['opt' . $i]); $i++) {

View File

@ -32,12 +32,12 @@
*/
function AddServerToPool(form) {
var IntOrIp
var IntOrIp;
var theSel = form['servers[]'];
if (form.type.selectedIndex == 0)
IntOrIp = form.ipaddr;
else
IntOrIp = form.interface;
IntOrIp = form.iface;
if (form.type.selectedIndex == 1) {
if (!form.monitorip.value) {