摘要: 今天看了JavaScript的正则表达式,之所以会记录下,是遇到了下面这个问题: 1 var searchString = "Now is the time and this is the time and that is the time"; 2 var pattern = /t\w*e/g; 3 var matchArray; 4 var str = ""; 5 matchArray = pattern.exec(searchString); 6 console.log(matchArray); 7 for(var i = 0;i... 阅读全文
posted @ 2012-08-21 20:46 AntWu 阅读(153) 评论(0) 推荐(0) 编辑
摘要: 今天了解了JavaScript的转义。分别是JSON转义、HTML转义、String转义等。 主要会导致XSS漏洞,由于是内部资料,这里不分析了。 Escape sequencesPropertiesDescription\bBackspace.\fForm feed.\nNewline.\ONul character.\rCarriage return.\tHorizontal tab.\vVertical tab.\'Single quote or apostrophe.\"Double quote.\\Backslash.\dddThe Latin-1 characte 阅读全文
posted @ 2012-08-21 20:40 AntWu 阅读(237) 评论(0) 推荐(0) 编辑