Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

DataObjectManager Module

Discuss the DataObjectManager module, and the related ImageGallery module.

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

UTF-8 Bug


5 Posts   1295 Views


14 June 2009 at 8:42am Community Member, 34 Posts

Hi UncleCheeze!

Sorry to hassle with that, but there seems to be a UTF-8 encoding bug using the DataObjectManager and the latest trunk release of SilverStripe. This wasn't happening before.

I need the latest trunk release because I need translations. Since the latest trunk release is more stable than the beta release, I have no choice but using it. Why SS aren't releasing a stable 2.3.2 release? I donnu.

But here's the bug. Maybe there's a quick fix. I hope so :

Looking at the forum, SilverStripe's team claim that they handle UTF-8 caracters. All data is coded in UTF-8 values. So, if I have a page with accents in any text fields, it'll encode properly. Even though phpMyAdmin won't show correctly the accents, in the CMS and in the Live site, the accents show correctly.

If I use your DataObjectModule, I can enter UTF-8 caracters. They show well in the popup. But in the list, and in the live site, they don't show correctly. If I open the popup (edit the record) again, the accent shows well, but in the list, they don't. And one more wierd thing : if I look the record, in PhpMyAdmin, the accents show correctly (the normal behavior is they don't show correctly... because SS doesn't use MySQL directive SET CHARSET = 'utf-8').

I would like to send you a picture. But the forum doesn't allow me.

Any idea?

Thanks, JP


14 June 2009 at 8:44am Community Member, 34 Posts

picture? How can I send a picture as an attachment?


14 June 2009 at 9:00am Community Member, 34 Posts

Here's a PDF explaining the bug :


14 June 2009 at 9:35am Community Member, 34 Posts


Please, include charset meta-information in the head of your templates :

      <% base_tag %>
      <meta content="text/html; charset=utf-8" http-equiv="Content-type"/>




15 June 2009 at 6:28am 4085 Posts

Whew! Thanks a lot, Johnny. Glad it was a quick fix. You rock!