urllib.quote DOT character( . ) in python -


i trying use urllib.quote on dot character (.) in python not getting desired outptut.

>>> urllib.quote(".") '.' >>> urllib.quote_plus(".") '.' 

but when unquote %2e using urllib.unquote get

>>> urllib.unquote("%2e") '.' 

so, question why not able %2e output when use quote or quote_plus on .

dots not need escaped. however, unquote converts %xx characters since valid encode character, no matter if necessary or not.


Comments

Popular posts from this blog

jquery - Invalid Assignment Left-Hand Side -

javascript - Preserving URL fragment through CAS sign-on -

asp.net mvc - Implementing normal user/pass, Twitter & Facebook auth -