Jump to:

23477 Posts in 18941 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » German umlauts problem in IE7

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 2118 Views
  • spierala
    Avatar
    Community Member
    80 Posts

    German umlauts problem in IE7 Link to this post

    hello all,

    I have a strange problem just in IE7. German umlauts (öäü) do not appear correctly. This problem appears only with my custom silverstripe input fields for page content. Normal page content is shown correctly... there umlauts appear in the database as html-code like ä [=ä]

    Can I somehow tell my input fields to convert umlauts to html-coded characters similar to the standard content text input seems to do it?

    And one additional question: why is the silverstripe database encoded latin1-swedisch? I guess utf8 could solve the umlauts problems. I also tried this to change the collation manually in the database to utf8, but the Strings somehow arrive wrong in the database.

    Thanks for your help,
    florian

  • slamby
    Avatar
    Community Member
    21 Posts

    Re: German umlauts problem in IE7 Link to this post

    Florian,
    you need to do some research on a topic called character encoding / character decoding.

    I'll give you some hints, which will get you going:
    If I type something here, my editor or browser has set a character encoding. Lets say utf-8. Now you store it to your database. Most people do not know, which character encoding there database is actually using. MySQL for example uses latin 1 per default. So it could be that your transmitted data is stored in latin 1 instead of your original encoding. Next step is when you want to pick up the data again from your database to display it somewhere. It could be that your database delievers the data in a different encoding than it uses to store it... Not to mention the client i. e. webbrowser, which will show it up again. Do you know, it is using utf-8, latin1 or whatever to show what it has got to display?

    You can only solve this, if you know exactly what is going on and where it is happening. Every step can be configured or manipulated. Google provides a lot of stuff on that issue.

    Hope this helps.

  • spierala
    Avatar
    Community Member
    80 Posts

    Re: German umlauts problem in IE7 Link to this post

    hey slamby,

    thanks for your answer. I tried so input the data with a different browser (Safari)... then suddenly the data arrived correctly in the database...

    Florian

  • ChrisBryer
    Avatar
    Community Member
    95 Posts

    Re: German umlauts problem in IE7 Link to this post

    one other thing to check is if your ss templates are encoded in utf-8. its usually a setting in the authoring software (notepad++, dreamweaver, whatever you are using). I know that makes a difference for the translated static text stored in the lookup tables like mysite/lang/en_US.php, but not sure if it makes a difference with content from the database. its normal to see the translated umlauts in the database.

    hope it helps,

    -Chris

  • spierala
    Avatar
    Community Member
    80 Posts

    Re: German umlauts problem in IE7 Link to this post

    hello!

    it finally helped to include the meta tag to the head of the main page.ss template file:

    <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>

    greetz,
    florian

    2118 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.