0

I have a problem with encoding of PHP and Mysql. The encoding of the html page & the php page is utf-8; database, table and column is utf8_unicode_ci. I use Punjabi Language that is an indic language. The text in the table in phpMyAdmin appears as ਉਸਤਤ when I insert values with a textbox and php. I tried using LOAD DATA LOCAL INFLIE, but now the values appear correctly in phpMyAdmin but doesn't match with the encoding of the html page. They appear as ??????. The encoding of the uploaded text file is UTF-8...

The encoding of the pages doesn't match. I want to use the encoding uploaded by the text file. But I am not able to figure it out.

Please help...

1 Answer 1

1

Issue a SQL query CHARSET utf8 before issuing other commands. This will change the connection character set to UTF-8.

Reference : http://dev.mysql.com/doc/refman/5.0/en/charset-connection.html

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.