Anoop Anoop - 1 month ago 13
PHP Question

– like symbols when using text editor

When I used text editors to insert text into database, symbols like

- , '
etc get converted to
–
like symbols. How can I avoid these symbols?

Answer

Set names to UTF8 before inserting into your database.

SET NAMES utf8

It sounds like your connection is using latin1 encoding. I struggled with the same thing for months.

http://forums.mysql.com/read.php?103,46870,47245