# -*- coding:utf-8 -*- #__author__ = "林深见鹿海蓝见鲸" from urllib.parse import unquote,quote def Unquote(): url = 'http%3A//123' unquote_url = unquote(url) print("解码前url",url) print("解码后url:",unquote_url) def Quote(): url = 'http://123' quote_url = quote(url) print("编码前url",url) print("编码后url:",quote_url) Unquote() # Quote()