Sample code for 30+ languages & platforms
Chilkat2-Python

StringBuilder EntityDecode

Demonstrates the Chilkat StringBuilder EntityDecode method to decode HTML entities.

Chilkat Chilkat2-Python Downloads

Chilkat2-Python
import chilkat2

# Decode the following HTML entities, replacing each with the character represented.
s = "é é é Latin small letter e with acute"

sb = chilkat2.StringBuilder()

sb.Append(s)
sb.EntityDecode()

# Output: é é é Latin small letter e with acute
print(sb.GetAsString())