On WAMPServer, I create a COM object and retrieve data in Russian for them:

$sh4 = new COM("Sh4Ole.Sh4App"); $Goods=$sh4->Goods(10); echo $sh4->ValByName($Goods,'1.210.2.0').'<br>'; 

I get this:

Ia? Oeie Nie? Eoi

PHP 5.6, everything is set to utf-8.

On another server with IIS7 and php 5.4, the same code produces text in cp1251, which I easily convert using iconv.

And here, as I understand it, cp-1251 is displayed in ISO-8859-1 encoding, but only in similar ASCII characters. And if you run a php script from the win command line, then cp-1251 is output, and if you write the displayed value in the database or display it in the browser, then that's the problem.

    0