fwartner's avatar

Having encoding problems

Hey,

i´m working on a project atm and use summernote for some content. I am using a snippet to save base64 images as "normal file" on my filesystem when i´m uploading an image with summernote. Everything´s working fine. But.. When i´m saving some german letters like ä,ü or ö i amm getting stuff like Speck (süße Sorte) 150 g (wenig gesalzen, nicht geräuchert)`..

I want the normal letter like ä,ü and ö.. Any suggestions?

Snippet: https://gist.github.com/franquis/9ea58a173061c2f49f5a Screenshot: https://infinit.io/_/BLbpKUQ

0 likes
3 replies
opheliadesign's avatar

I'm assuming you're saving the output from Summernote on a MySQL table? If so, have you tried directly entering those characters into the table without using Summernote and seeing if they're stored correctly? This would help confirm or rule out Summernote as the source.

ARCANEDEV's avatar
  • Save your files with UTF-8 encoding.
  • Check your database encoding, use utf8_unicode_ci or utf8_general_ci.
  • You can use utf8_encode and utf8_decode to encode and decode your outputs.
2 likes
fwartner's avatar

Thanks.. But it was because something with the DOM wasn´t right.. It´s fixed now. :)

Please or to participate in this conversation.