Ben
Ben

Reputation: 62384

What encoding is this?

How can I determine what encoding this string is?

Sometimes, it’s the little things that make us the happiest.

Upvotes: 6

Views: 2446

Answers (1)

Ignacio Vazquez-Abrams
Ignacio Vazquez-Abrams

Reputation: 798646

It's UTF-8 decoded as Latin-1 encoded as UTF-8 decoded as CP1252.

>>> u'’'.encode('cp1252').decode('utf8').encode('latin1').decode('utf8')
u'\u2019'

Seriously... who does this?

Upvotes: 19

Related Questions