Jump to content

Problem With Accents In Mysql


Guest

Recommended Posts

You're not outputting UTF-8. Well, technically yes you are, but whatever's displaying the characters doesn't think they're UTF-8.

 

For PHP send another header:

header("Content-Type: text/html; charset=utf-8");

(or any other text/* type)

 

For HTML:

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

(same as the header above)

 

For XML:

<?xml version="1.0" encoding="utf-8" ?>

 

 

Though it could be you're doubly-encoding the stuff. Remove the call to utf8_encode() and see if that fixes it. But the above changes are still important so make sure something like them is in place.

Well when i look in phpmyadmin the accents aren't correctly displayed

"é" are displayed as "é" in the database

 

so i don't think the problem is about output... I also have other strings with accents on the same page and they are correctly displayed. I only have a problem with accents coming from SQL.

 

I also tryed without utf8_encode()

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.