| 
	
 | 
 Posted by Stephen Kay on 03/23/06 03:04 
in article C0475AB8.59ECA%sk@karma-lab.nospam.com, Stephen Kay at 
sk@karma-lab.nospam.com wrote on 3/22/06 7:52 PM: 
 
>  
> I am writing some php functions to run pages of my web site through 
> altavista's babelfish language translation services. 
>  
> It works, kind of, but I have run into a problem with multi-byte 
> international characters. 
>  
> If I call the desired URL query string directly by typing it into a browser, 
> it returns a doc, showing in the header: 
>  
> http-equiv="content-type" content="text/html; charset=UTF-8 
>  
> and properly displays the additional international characters. 
>  
> If I call the exact same URL from inside my php code, using curl, the 
> resulting document appears to have the same UTF-8 encoding in the header, 
> yet the international characters are lost. I just get ? instead. 
 
 
Nevermind, I found the answer: 
 
Need to use mb_convert_encoding() on the results of curl. 
 
--  
Stephen Kay 
Karma-Lab   sk@karma-lab.NOSPAM.com 
                        ^^^^^^^
 
  
Navigation:
[Reply to this message] 
 |