(1)编码
import urllib
after = urllib.quote(befor)
(2)去掉字符串前后两段的空格
name = " 1asdf asasdf dsaf asdf "
name = name.strip()
import urllib
after = urllib.quote(befor)
(2)去掉字符串前后两段的空格
name = " 1asdf asasdf dsaf asdf "
name = name.strip()