错误 javascript 函数
Error javascript function
您好,我正在使用 Dreamweaver,它在第 78 行检测到此 javascript 函数的错误。我无法发现问题。帮帮我。
function FrontPage_Form1_Validator(theForm)
{
var checkOK = "0123456789-.,";
var checkStr = theForm.theField.value;
var allValid = true;
var validGroups = true;
var decPoints = 0;
var allNum = "";
for (i = 0; i < checkStr.length; i++)
{
ch = checkStr.charAt(i);
for (j = 0; j < checkOK.length; j++)
if (ch = = checkOK.charAt(j)) //------This is line 78------//
break;
if (j = = checkOK.length)
{
allValid = false;
break;
}
if (ch = = ".")
{
....
//will cut code here since it's not letting me post with so much code.
你的等号之间有一个space。
将 = =
更改为 ==
。
您好,我正在使用 Dreamweaver,它在第 78 行检测到此 javascript 函数的错误。我无法发现问题。帮帮我。
function FrontPage_Form1_Validator(theForm)
{
var checkOK = "0123456789-.,";
var checkStr = theForm.theField.value;
var allValid = true;
var validGroups = true;
var decPoints = 0;
var allNum = "";
for (i = 0; i < checkStr.length; i++)
{
ch = checkStr.charAt(i);
for (j = 0; j < checkOK.length; j++)
if (ch = = checkOK.charAt(j)) //------This is line 78------//
break;
if (j = = checkOK.length)
{
allValid = false;
break;
}
if (ch = = ".")
{
....
//will cut code here since it's not letting me post with so much code.
你的等号之间有一个space。
将 = =
更改为 ==
。