编码
-
from urllib.parse import quote
-
text = quote(text, 'utf-8')
注:text为要进行编码的字符串
解码
-
fro urllib.parse import unquote
-
text = unquote(text, 'utf-8')
-
链接
码云
from urllib.parse import quote
text = quote(text, 'utf-8')
注:text为要进行编码的字符串
fro urllib.parse import unquote
text = unquote(text, 'utf-8')
链接码云