Jump to content

[SOLVED] Euro symbol and accented characters in MYSQL


fohanlon

Recommended Posts

Hi

 

Can anyone point out a solution to my problem

 

I have built a cms where a user can all in content. The content can contain euro symbols and accented and they get stored ok in a text field in the mysql table.

 

The table is set as utf-8-general-ci.  As i read that thsi was the best for storing all symbols.

 

 

Problem is when the select in done in a web page to view the content the characters are appearing as square boxes.  Is there comething like htmlspecialchars I should be running on the content to fix this output?

 

Many thanks,

 

Fergal.

 

 

 

Link to comment
Share on other sites

I have actually had a similar problem before, and I solved it making my own escape phrases sorta like xhtml has   or "  I just made stuff like € or &passo; and then I did a replace on the output and altered all inputers to use this.

 

Not a good idea. Everything will work as-is if everything is UTF-8.

 

Thanks effigy

 

How would this work in a mysql select statement?

 

Fergal.

 

http://www.phpfreaks.com/forums/index.php/topic,159313.msg694931.html#msg694931

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.