问题
I tried a lot of different things to get my string correctly displayed but I can't make it work.
That's the string:
f=C3=A4hrt (German word: fährt)
My file is encoded in utf-8, the file is loaded within Joomla.
I tried both
$geschichte->inhalt = utf8_encode($geschichte->inhalt);
and
$geschichte->inhalt = mb_convert_encoding($geschichte->inhalt, "UTF-8");
but nothing works.
I hope someone can help me...
回答1:
This encoding has nothing to do with UTF-8 or such, it looks like quoted printable encoding, which is most often found in emails. Perhaps you are parsing emails and will need to heed the specific email headers and decode the content appropriately. Either way, quoted_printable_decode helps here:
echo quoted_printable_decode('f=C3=A4hrt'); // fährt
来源:https://stackoverflow.com/questions/52078879/decoding-c3-a4-in-a-string