I have a strange problem. In PHP
I want to communicate to a Web Service with SOAP.
$soapURL = "http://www.somedomain.com/xyz.asmx?WSDL";
$soapParameters = Array('login' => "123", 'password' => "pwd", 'soap_version' => SOAP_1_2, 'exceptions' => True) ;
$client = new SoapClient($soapURL, $soapParameters);
With XAMPP it works locally without problems.
When I try it on my web server, I get the following error message:
Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://www.somedomain.com/xyz.asmx?WSDL' : Input is not proper UTF-8, indicate encoding ! Bytes: 0xFC 0x6C 0x74 0x69 in ...
The error raises at the last line of my code example.
Any Ideas?
mb_detect_encoding($soapURL);
says the String is of format ASCII- I tried to convert every string to UTF-8 with
utf8_encode
,iconv
and mb_convert_encoding... - first line of php file is:
header('Content-type: text/html; charset=utf-8');