任何 urlencode
urlencode 是一种编码方式,用于将 URL 中的特殊字符转换为可被浏览器和服务器理解的格式。任何字符串都可以通过 urlencode 进行编码,不限于特定类型或格式。
例如,以下字符串可以通过 urlencode 进行编码:
- Hello, world!
- 你好,世界!
- http://example.com/?q=hello world
- {"name": "John", "age": 30}
编码后的结果如下:
- Hello%2C+world%21
- %E4%BD%A0%E5%A5%BD%EF%BC%8C%E4%B8%96%E7%95%8C%EF%BC%81
- http%3A%2F%2Fexample.com%2F%3Fq%3Dhello+world
- %7B%22name%22%3A+%22John%22%2C+%22age%22%3A+30%7D
原文地址: https://www.cveoy.top/t/topic/croc 著作权归作者所有。请勿转载和采集!