Jump to content

How to display russian on webpage ?


Recommended Posts

hello sorry to post in english but only you can help i think.

I have a self coded webpage that tries to pull from de prestashop DB russian texts (the site is english/russiian), what i did is this so far :

 

$db->query("SET NAMES 'utf-8'");

$db->query("SET CHARACTER SET utf8");

 

my page is encode in utf8, the header has this:

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

but still only can display ?????.

 

 

thanks in advance for your help !!

Link to comment
Share on other sites

Hi

Try this charset

 

charset=windows-1251

 

some information

http://en.wikipedia.org/wiki/Windows-1251

 

Windows-1251 (a.k.a. code page CP1251) is a popular 8-bit character encoding, designed to cover languages that use the Cyrillic script such as Russian, Bulgarian, Serbian Cyrillic and other languages. It is the most widely used for encoding the Bulgarian, Serbianand Macedonian languages.

In modern applications, Unicode is a preferred character set.

Windows-1251 and KOI8-R (or its Ukrainian variant KOI8-U) are much more commonly used than ISO 8859-5, which never really caught on. In the future, both may eventually give way to Unicode.

Link to comment
Share on other sites

Hi Try this charset charset=windows-1251 some information http://en.wikipedia.org/wiki/Windows-1251 Windows-1251 (a.k.a. code page CP1251) is a popular 8-bit character encoding, designed to cover languages that use the Cyrillic script such as Russian, Bulgarian, Serbian Cyrillic and other languages. It is the most widely used for encoding the Bulgarian, Serbianand Macedonian languages. In modern applications, Unicode is a preferred character set. Windows-1251 and KOI8-R (or its Ukrainian variant KOI8-U) are much more commonly used than ISO 8859-5, which never really caught on. In the future, both may eventually give way to Unicode.

 

Incorrect recommendation to use Win-1251 when whole engine and database tables developed for UTF-8.

In any case old 8-bit encodings must die... as in the quote below: " In the future, both may eventually give way to Unicode."

Edited by Nick Fedchik (see edit history)
Link to comment
Share on other sites

  • 4 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...