« Coder avec Unicode/Conversion » : différence entre les versions

Contenu supprimé Contenu ajouté
Ligne 45 :
| <source lang=php>print mb_convert_encoding($chaine, 'HTML-ENTITIES', 'UTF-8');</source> || <source lang=html>é é $ €</source> || <source lang=html>...</source>
|-
| <source lang=php>print json_encode($chaine);</source><ref>https://magp.ie/2011/01/06/remove-non-utf8-characters-from-string-with-php/</ref> || <source lang=html>é \u00e9 $ \u20ac</source> || <source lang=html>...</source>
|-
| <source lang=php>print json_decode($chaine);</source> || <source lang=html></source> || <source lang=html>...</source>