ID: 28640
User updated by: clemens at gutweiler dot net
Reported By: clemens at gutweiler dot net
Status: Open
Bug Type: WDDX related
Operating System: Linux 2.6.3
PHP Version: 5.0.0RC2
New Comment:
<?php
var_dump( wddx_deserialize( '<?xml version="1.0" encoding="ISO-8859-1"
?>'."\n".wddx_serialize_value( 'te�st' ) ) );
?>
this works.
it works also if the data are encoded with utf-8.
but is a bc break!
Previous Comments:
------------------------------------------------------------------------
[2004-06-05 10:50:18] clemens at gutweiler dot net
Description:
------------
wddx_deserialize stops deserializing at german umlaut character.
PHP Version: 5.0.0RC3RC2
This code works properly on PHP 4
Reproduce code:
---------------
<?php
$wddx_data = 'test';
var_dump( wddx_deserialize( wddx_serialize_value( $wddx_data ) ) );
$wddx_data = 'te�st';
var_dump( wddx_serialize_value( $wddx_data ) );
var_dump( wddx_deserialize( wddx_serialize_value( $wddx_data ) ) );
$wddx_data = array( 'string' => 'te�st' );
var_dump( wddx_deserialize( wddx_serialize_value( $wddx_data ) ) );
?>
Expected result:
----------------
string(4) "test"
string(83) "<wddxPacket
version='1.0'><header/><data><string>te�st</string></data></wddxPacket>"
string(5) "te�st"
array(1) {
["string"]=>
string(5) "te�st"
}
Actual result:
--------------
string(4) "test"
string(83) "<wddxPacket
version='1.0'><header/><data><string>te�st</string></data></wddxPacket>"
string(2) "te"
NULL
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=28640&edit=1