开发者

SQL Server - Special characters not recognise by PHP (ODBC)

I am trying to display some开发者_运维技巧 information from SQL Server to my PHP site. I am using ODBC connection for that one.

My Issue is : Special characters are not recognised and it is displaying "question mark (?)" in my site. (This works in my other ASP site)

What I am missing here ? Please help me.

Thanks in advance.


I use some special MSSQL query converter and then ICONV in the PHP side like this:

   SELECT  CAST(Remarks AS TEXT) Remarks FROM r_table;

And in the PHP, say the text is in CodePage 1255:

   iconv('CP1255', 'UTF-8', $remark);

hope that's helps.


What's your character encoding for the ODBC connection? It should be some UTF with proper handling on PHP side...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜