#38657 [Com]: WDDX does not work anymore

2006-08-30 Thread werner at esmt dot org
 ID:   38657
 Comment by:   werner at esmt dot org
 Reported By:  tom at ideaweb dot de
 Status:   Feedback
 Bug Type: WDDX related
 Operating System: Debian, OSX
 PHP Version:  4.4.4
 New Comment:

i did and it works for my test case on my mac and it seems there are no
problems with my linux server too :)

but the behaviour of ex. german 'umlaute' changed from


 äbbBBB


to


 bbBBB


but its my problem...

did you know when i can expect the next php4 version? i feel not safe
with a snapshot on my production machine...

thx a lot, thomas


Previous Comments:


[2006-08-30 12:34:35] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





[2006-08-30 12:32:34] tom at ideaweb dot de

Description:

I have a small cms which works over year, but with the upgrade from
php-4.4.2 on Debian Sarge to php-4.4.4 wddx does not work anymore. I go
back to the old version and it works. I used the same configuration
script for both php versions.

The problem is, its not easy for me as an admin to find the right
portion of code, but tried to reproduce this on my mac, not linux,
because its a production machine. i got malformed wddx output with my
show() method. on my linux machine the wddx output was empty.

i hope it helps and i made no mistakes :)

Reproduce code:
---
name = $pName;
$this->packet = wddx_packet_start( $pName );
}/*}}}*/

function setVar( $pName, $pValue, $pOrd = false ) {/*{{{*/

eval( "\$$pName = \$this->entities(\$pValue, \$pOrd);" 
);

wddx_add_vars( $this->packet, $pName );

}/*}}}*/

function show() {/*{{{*/

//var_dump( wddx_packet_end( $this->packet ) );exit;

if( !$this->packet ) return false;

return wddx_packet_end( $this->packet );
}/*}}}*/

function entities( $pString, $pOrd = false ) {/*{{{*/

if ( is_array( $pString ) ) {
foreach( $pString as $key => $value ) {
$pString[$key] = CMS_WDDX::entities( 
$pString[$key], $pOrd );
}
}
elseif ( is_string( $pString ) ) {

if( strpos( phpversion(), '4' ) === 0 ) {

if ( $pOrd === true ) {

if ( ideacms_isutf8( $pString ) 
) {
if( $pTemp = 
@utf8_decode( $pString ) ) {
$pString = 
$pTemp;
}
}

$pString = 
CMS_WDDX::unentities( $pString );

$temp = htmlspecialchars( 
$pString, ENT_NOQUOTES );

$pString = '';

for( $i = 0; $i < strlen( $temp 
); $i++ ) {

$ord = ord($temp{$i});

if($ord >= 126){
$pString .= 
"&#".$ord.";";
}
else {
switch($ord){
case 34 
:

$pString .= '"';

break;
case 39 
: 
  

#27908 [Com]: xml default_handlers not being called when using libxml (works fine with expat)

2005-03-18 Thread werner at esmt dot org
 ID:   27908
 Comment by:   werner at esmt dot org
 Reported By:  ahundiak at ingr dot com
 Status:   Verified
 Bug Type: XML related
 Operating System: *
 PHP Version:  5CVS-2005-03-06
 New Comment:

..but what can i do, if i want to run my current php4 
applications with php5 and other webs the new libxml2 
stuff? its not really a solution, only a workaround ...


Previous Comments:


[2005-03-06 19:45:41] [EMAIL PROTECTED]

It is a bug in the compatibility layer used when ext/xml is build with
libxml2. It works fine with expat. 




[2004-04-07 12:34:00] ahundiak at ingr dot com

Description:

As the test case shows, it does not appear that the default handler is
being called under PHP5RC1.  The other handlers seem to work but the
default handler is required to get the document type line.  PHP4.3.5
works. Using libxml2 2.6.5.



Reproduce code:
---
function x_default_handler($xp,$data) 
{ 
echo "x_default_handler $data\n"; 
} 
$xp = xml_parser_create(); 
xml_set_default_handler($xp,'x_default_handler'); 
xml_parse($xp,'',TRUE); 
xml_parser_free($xp); 
echo "Parse Test " . PHP_VERSION . " Done\n"; 


Expected result:

x_default_handler  
x_default_handler  
Parse Test 5.0.0RC1 Done 


Actual result:
--
Parse Test 5.0.0RC1





-- 
Edit this bug report at http://bugs.php.net/?id=27908&edit=1


#27908 [Com]: xml default_handlers not being called

2004-12-03 Thread werner at esmt dot org
 ID:   27908
 Comment by:   werner at esmt dot org
 Reported By:  ahundiak at ingr dot com
 Status:   Verified
 Bug Type: XML related
 Operating System: Linux
 PHP Version:  5CVS-2004-04-08
 New Comment:

...please, can somebody fix this bug?

thanx!


Previous Comments:


[2004-09-16 22:56:07] k at ailis dot de

I'm currently experiencing the same problem. The bug is still present
in PHP 5.0.1. 

I'm using libxml2 2.6.11 and libexpat 1.95.6.



[2004-08-06 15:29:13] tom at ideaweb dot de

i have the same problem too. in version 4 there are no 
problems, but in php5 this is broken. the bug is not 
fixed till 5.0.0. i think it is a very import "core" 
function to get "old" applications of version 4 
running!!



[2004-04-07 12:34:00] ahundiak at ingr dot com

Description:

As the test case shows, it does not appear that the default handler is
being called under PHP5RC1.  The other handlers seem to work but the
default handler is required to get the document type line.  PHP4.3.5
works. Using libxml2 2.6.5.



Reproduce code:
---
function x_default_handler($xp,$data) 
{ 
echo "x_default_handler $data\n"; 
} 
$xp = xml_parser_create(); 
xml_set_default_handler($xp,'x_default_handler'); 
xml_parse($xp,'',TRUE); 
xml_parser_free($xp); 
echo "Parse Test " . PHP_VERSION . " Done\n"; 


Expected result:

x_default_handler  
x_default_handler  
Parse Test 5.0.0RC1 Done 


Actual result:
--
Parse Test 5.0.0RC1





-- 
Edit this bug report at http://bugs.php.net/?id=27908&edit=1