我需要编码的URL在其中一个API中进行处理,但它需要完整的编码URL.例如,来自的URL:
http://test.site-raj.co/999999?lpp=1&px2=IjN
Run Code Online (Sandbox Code Playgroud)
必须成为编码的URL,如:
http%3a%2f%test%site%2draj%2eco%2f999999%3flpp%3d1%26px2%3dIjN
Run Code Online (Sandbox Code Playgroud)
我需要对每个符号进行编码,甚至像上面的点(.)和连字符( - )一样.