I am making a request to a webservice with PHP (SoapClient), and when I have special characters, error / deformation is occurring.
What I've already tried:
Set the parameter 'encoding'=>'ISO-8859-1'
or 'encoding'=>'UTF-8'
.
I also tried to put utf8_encode
/ utf8_decode
.
I tried to use iconv
and nothing.
What happens:
Sometimes you can not make the request, sometimes it does however there on the server is unconfigured or with "?" or without the accented character.
Errors also occur:
Invalid byte 2 of 3-byte UTF-8 sequence.
SOAP-ERROR: Encoding: string '2 test \ xe1 ...' is not a valid utf-8 string
What I did not try:
I did not try to use the mb( Multibyte String )
functions, because it is not enabled, as I'm at work, it's a novel request to enable.
For this reason, I would like to know if the only output is to use an mb function. I tried all the possible tips I found out there and nothing worked 100%.