摘要:
str为要去除空格的字符串:去除所有空格: str = str.replace(/\s+/g,""); 去除两头空格: str = str.replace(/^\s+|\s+$/g,"");去除左空格:str=str.replace( /^\s*/, '');去除... 阅读全文
posted @ 2015-09-11 15:12
海角之上
阅读(248)
评论(0)
推荐(0)
摘要:
toLocaleUpperCase 方法:将字符转换为大写stringVar.tolocaleUpperCase( )必选的 stringVar 引用是一个 String 对象,值或文字。//转换成大写toUpperCase 方法返回一个字符串,该字符串中的所有字母都被转化为大写字母。strVari... 阅读全文
posted @ 2015-09-11 11:06
海角之上
阅读(4813)
评论(0)
推荐(0)
摘要:
例如网址:http://localhost:12085/My/OrderM.aspx?id=6 设置或获取对象指定的文件名或路径。 alert(window.location.pathname) 输出结果:/My/OrderM.aspx 设置或获取整个 URL 为字符串。 alert(window. 阅读全文
posted @ 2015-09-11 11:03
海角之上
阅读(453)
评论(0)
推荐(0)

浙公网安备 33010602011771号