Fix htmlentities and htmlspecialchars