By zeitenflug on
How do I treat German umlaute (ISO-8859-1) like ä, ö, ü in drupal modules? When I do drupal_set_title("Übersicht"), the U umlaut breaks.
How do I treat German umlaute (ISO-8859-1) like ä, ö, ü in drupal modules? When I do drupal_set_title("Übersicht"), the U umlaut breaks.
Comments
UTF-8
It seems that drupal outputs in UTF-8, so that's the character set you should be using, not ISO-8859-1.
I did a quick test, setting the tilte of a block coming from PHP to "Übsersicht", saving as UTF-8 and it worked fine.
Umlaute
I tried drupal_set_title(utf8_encode("Übersicht")) and it didn't work for the title. By "title" I mean the meta tag title for the browser. It works fine with text such as block titles. However, I can use umlaute in a title meta-tag. But why not in drupal?
Any solution to this yet?
Any solution to this yet? UTF-8 characters seem to be disappearing from page titles (at least I think they're UTF-8).
Or maybe it's a MySQL
Or maybe it's a MySQL problem: drupal_set_title('Hæmoglobin') seems to work ok.
Never mind, it's working
Never mind, it's working fine.