0

I have the following code:

echo html_entity_decode("„", ENT_QUOTES, "UTF-8");

Result is „ but expected result is .

I also tried ISO-8859-1 instead of UTF-8, but it's still the same.

Why isn't html_entity_decode working in this case?

David
  • 2,898
  • 3
  • 21
  • 57
  • That is a special character, not html entity. This might help. https://stackoverflow.com/questions/1262038/how-to-replace-microsoft-encoded-quotes-in-php – blupointmedia Dec 11 '19 at 17:29

1 Answers1

0

This is a special char, not html entity, so I thin this would be the right way.

<?php
    $str = "&#132;";
    echo htmlspecialchars_decode($str);

    ?>
Otávio Barreto
  • 1,536
  • 3
  • 16
  • 35