在Python中替换非ASCII字符
有谁知道如何在Python3中替换非ASCII CHAR? 我以一个示例为例,但它无法按照我想要的方式工作,那就是将新的Var修改为字符串。
body = "ALYSS - PYRAMID ♅"
newbody = body.encode('ascii', 'ignore')
Does anyone know how to replace a non ascii char in python3?
I use as an example but it doesn't work the way I want to, that is to modify the new var as a string.
body = "ALYSS - PYRAMID ♅"
newbody = body.encode('ascii', 'ignore')
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论