SOAP-ERROR: Encoding: string … is not a valid utf-8 string

前端 未结 6 618
情书的邮戳
情书的邮戳 2021-01-02 22:10

Hi I have a web service built using the Zend Framework. One of the methods is intended to send details about an order. I ran into some encoding issue. One of the values bein

6条回答
  •  佛祖请我去吃肉
    2021-01-02 22:43

    I fixed a problem like this using mb_convert_encoding with array_walk_recursive to walk into my POST parameters, named $params (array).

    Maybe this is useful for you:

    array_walk_recursive($params,function (&$item){
        $item = mb_convert_encoding($item, 'UTF-8');
    });
    

提交回复
热议问题