utf-8 issue

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
zahidiqbalbscs
Forum Newbie
Posts: 1
Joined: Mon Feb 22, 2010 1:36 am

utf-8 issue

Post by zahidiqbalbscs »

Hi,
I am getting very strange thing,
id title
179 ??????????
180 ??????????
181 اسفسدفسداف
the column titile = utf8_general_ci and its data type is text
when i try to input arabic from front end form then it generets "??????" and if i try to input from query manually then it works perfect.
May i know where i am wrong
User avatar
Apollo
Forum Regular
Posts: 794
Joined: Wed Apr 30, 2008 2:34 am

Re: utf-8 issue

Post by Apollo »

What kind of encoding does your front end use? What is the collation of your SQL connection?

And when you say "it generates ????", where/how do you inspect that?
edaili
Forum Newbie
Posts: 3
Joined: Tue Oct 05, 2010 6:58 am

Re: utf-8 issue

Post by edaili »

Hello
Im having a similiar problem
I am trying to retrieve data from oracle into PHP and I have successfully accomplished that, but the data appeared in question marks (??????), so I add the AMERICAN_AMERICA.AR8MSWIN1256 to NLS language in the registry for oracle and now the data appears as (ÓÇãÑ ÝíáíÈ ÚíÏ ÇáÚÏíáí). I tried encoding and all suggested character sets from IE and from the PHP code but had no results. I tried Windows-1256, UTF-8 & 16, I would appreciate some support for this issue
By the way anything else in the page that is not generated from the database and written in arabic appears in arabic OK with no problems so i have no problem with that, only with what is generated from the database.
windows-1256 generates (ÓÇãÑ ÝíáíÈ ÚíÏ ÇáÚÏíáí)
UTF-8 generates (����� � ����� )
Thank you
Post Reply