Looktrne Posted July 9, 2008 Share Posted July 9, 2008 I have some russian text in a mysql database I can see it fine in phpmyadmin but when my php script calls the database for it it shows as ????? for example Добро would show up as ?????? do I have to set the collation before calling to the database? sorry but I have never used anything except english in the past thanks for any help on this Paul Quote Link to comment Share on other sites More sharing options...
maxudaskin Posted July 9, 2008 Share Posted July 9, 2008 When inserting, try using HTMLSPECCHARS. http://ca3.php.net/manual/en/function.htmlspecialchars.php Quote Link to comment Share on other sites More sharing options...
Looktrne Posted July 10, 2008 Author Share Posted July 10, 2008 how can I pull the variable from the database and display it in the original russian format? Quote Link to comment Share on other sites More sharing options...
maxudaskin Posted July 10, 2008 Share Posted July 10, 2008 htmlspecialchars_decode() http://ca.php.net/manual/en/function.htmlspecialchars.php http://ca.php.net/manual/en/function.htmlspecialchars-decode.php Quote Link to comment Share on other sites More sharing options...
Looktrne Posted July 12, 2008 Author Share Posted July 12, 2008 I tried this in my querry and get nothing but ???? if I log into php my admin I see the russian but I cant seem to pull it into php in anyway to display the russian from the database can someone please provide an example of pulling the content from the database and displaying the russian? I really need an example nothing I tried has worked.... thanks for any help on this guys Paul Quote Link to comment Share on other sites More sharing options...
unsider Posted July 12, 2008 Share Posted July 12, 2008 Can you post some code? We might be able to help you more. Quote Link to comment Share on other sites More sharing options...
xtopolis Posted July 12, 2008 Share Posted July 12, 2008 Save your page in a different encoding. When you do file->save as: At the bottom choose: Encoding-> UTF-8 [instead of the default ANSI] However, I do not know if there are any downsides to this. This is simply what I did when I wished to display Russian chars on a site I helped build. If there are any downsides, I would like to hear them so I can change as well. Quote Link to comment Share on other sites More sharing options...
vikramjeet.singla Posted July 12, 2008 Share Posted July 12, 2008 Hi change the charset in html when you are displaying page on client site. refer below: <meta http-equiv="content-type" content="text/html; charset=KOI8-R"> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.