Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

PHP, MySQL and Russian Text

Posted on 2008-06-26
3
Medium Priority
?
801 Views
Last Modified: 2013-12-12
Hi,
I have a DB where I keep some russian text. And a php script which queries the DB and echo's this russian text on the to the browser.
When I check the table which contains russian text using PHP MyAdmin, I can see the russian text correctly. But when I open the page, all russian characters are appears as ? (Question Mark)

I have this
<?php
header('Content-type: text/html; charset=utf-8') ;
?>
in the begining of the script but it doesn't help.

Can someone help me pleaseee...
0
Comment
Question by:bilgehanyildirim
  • 2
3 Comments
 
LVL 36

Assisted Solution

by:Loganathan Natarajan
Loganathan Natarajan earned 1200 total points
ID: 21873695
better try to set it on the page itself
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

Open in new window

0
 
LVL 36

Assisted Solution

by:Loganathan Natarajan
Loganathan Natarajan earned 1200 total points
ID: 21873698
also check right click whether the utf-8 encoding is set to the page
0
 
LVL 1

Accepted Solution

by:
webjema earned 800 total points
ID: 21882059
Also check connection to the database.
Use mysql commands (before your first query)
SET NAMES 'utf8'
SET CHARACTER SET utf8
for right encoding.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses

926 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question