删除爬取字符串中的特殊字符

# 删除爬取字符串中的特殊字符
def SubPunctuation(str):
    s = re.sub(u"[+——!,。?、~@#¥%……&*()::¶]+", u"",str)
    return s

 

posted @ 2020-09-02 16:04  短戈行  阅读(533)  评论(0编辑  收藏  举报