- escape, encodeURIComponent和encodeURI
-
对于ASCII字符,这三个函数的作用都是将字符转换成百分比编码( Percent-encoding ),区别是各自排除编码的字符不同:
escape() will not encode: @*/+
encodeURI() will not encode: ~!@#$&*()=:/,;?+\'
encodeURIComponent() will not encode: ~!*()\'
请看测试页面: test_for_escape_and_encodeURIComponent.html
此外,escape...
- 时间:2009年03月17日 08:52 标签:
escape
encodeURIComponent
encodeURI
js
前端开发
共 1 记录 1 / 1 页