How to work with unicode in Python

后端 未结 6 1121
一生所求
一生所求 2020-12-31 05:42

I am trying to clean all of the HTML out of a string so the final output is a text file. I have some some research on the various \'converters\' and am starting to lean tow

6条回答
  •  星月不相逢
    2020-12-31 06:13

    Look at the codecs standard library, specifically the encode and decode methods provided in the Codec base class.

    There's also a good article here that puts it all together.

提交回复
热议问题