JS学习网址:http://www.w3school.com.cn/js/index.asp
js判断undefined类型
if (reValue== undefined){
alert("undefined");
}
发现判断不出来,最后查了下资料要用typeof
方法:
if (typeof(reValue) == "undefined") {
alert("undefined");
}
typeof 返回的是字符串,有六种可能:"number"、"string"、"boolean"、"object"、"function"、"undefined"
----------------------正则表达式--------------------
正则表达式中/i,/g,/ig,/gi,/m的区别和含义
/i (忽略大小写)
/g (全文查找出现的所有匹配字符)
/m (多行查找)
/gi(全文查找、忽略大小写)
/ig(全文查找、忽略大小写)
---------------------------------------------------------------------