RE: [PEAR-DEV] SOAP character encoding bug

From: Date: Sat, 11 May 2002 16:17:50 +0000
Subject: RE: [PEAR-DEV] SOAP character encoding bug
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-6044@lists.php.net to get a copy of this message
Hello, Taking a a look to the soap classes, It seems, as you remark, the parser does not convert the degree symbol automaticly as others symbols. What I do not undestand it s why it works with others entities ? Maybe I m wrong, but I beliebe the jobs is done with the xml parser. The code sees the values have to be converted in the SOAP_Value object (_getSoapType method), but on line 620 : if ($type == 'string') $doconvert = TRUE; ($type is set by gettype php functions) and line 626 : if ($doconvert) { $dt = new SOAP_Type_dateTime($value); if ($dt->toUnixtime() != -1) { $type = 'dateTime'; $value = $dt->toSOAP(); } } else ..... It does not convert anything, and I did not find any conversions elsewhere. So the code should be: if ($doconvert) { $dt = new SOAP_Type_dateTime($value); if ($dt->toUnixtime() != -1) { $type = 'dateTime'; $value = $dt->toSOAP(); } else { $value = htmlentities( $value ); } } else ..... Just a first note, any others ideas ? hth pa

« previous php.pear.dev (#6044) next »