function isCharsInBag (s
{
var i
for (i =
{
c = s
if (bag
return c;
}
return "";
}
檢查函數:
function ischinese(s)
{
var errorChar;
var badChar = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
errorChar = isCharsInBag( s
if (errorChar != "" )
{
report=report+"請重新輸入中文n";
return false;
}
return true;
}
From:http://tw.wingwit.com/Article/program/net/201311/14103.html