Req #51939 [PATCH]: Add xml_set_entity_decl_handler function

2011-07-19 Thread dav...@php.net
Edit report at https://bugs.php.net/bug.php?id=51939&edit=1

 ID: 51939
 Patch added by:     dav...@php.net
 Reported by:mchenryc at gmail dot com
 Summary:Add xml_set_entity_decl_handler function
 Status: Assigned
 Type:   Feature/Change Request
 Package:XML related
 PHP Version:trunk-SVN-2010-05-28 (SVN)
 Assigned To:davidc
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: bug51939.patch
Revision:   1311092480
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51939.patch&revision=1311092480


Previous Comments:

[2010-05-28 01:40:45] mchenryc at gmail dot com

Description:

When parsing XML, PHP has no way to set a handler for general entities, though 
a 
handler can be set for unparsed entities.

Expat has deprecated the XML_SetUnparsedEntityDeclHandler in favor of 
XML_SetEntityDeclHandler, which is called for all entity types (including 
general 
and unparsed).

http://expat.cvs.sourceforge.net/viewvc/expat/expat/lib/expat.h?
revision=1.80&view=markup#l_311

PHP should add the xml_set_entity_decl_handler function to allow handling of 
all 
entity declarations.


Test script:
---
$data = ']>&generalEntity;';

function 
h_entity_decl($parser,$entity_name,$is_parameter_entity,$value,$base,$system_id,$public_id,$notation_name)
 {
echo "$entity_name - $is_parameter_entity - $value";
};

$parser = xml_parser_create();
xml_set_entity_decl_handler($parser, 'h_entity_decl');

xml_parse($parser,$data,false) or 
die (sprintf("XML Error: %s at line %d\n", 
 xml_error_string(xml_get_error_code($parser)),
 xml_get_current_line_number($parser)));
xml_parser_free($parser);


Expected result:

It should run with the following output:

generalEntity - 0 - General Entity


Actual result:
--
Fatal Error: Call to undefined function xml_set_entity_decl_handler()







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


Req #51939 [PATCH]: Add xml_set_entity_decl_handler function

2011-07-21 Thread dav...@php.net
Edit report at https://bugs.php.net/bug.php?id=51939&edit=1

 ID: 51939
 Patch added by:     dav...@php.net
 Reported by:mchenryc at gmail dot com
 Summary:Add xml_set_entity_decl_handler function
 Status: Assigned
 Type:   Feature/Change Request
 Package:XML related
 PHP Version:trunk-SVN-2010-05-28 (SVN)
 Assigned To:davidc
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: bug51392-ws
Revision:   1311251978
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51392-ws&revision=1311251978


Previous Comments:

[2011-07-19 12:22:21] dav...@php.net

I've added a patch for this but I'd like to write a few more tests before 
committing it. If you could apply it and let me know if this helps you that'd 
be 
nice.

----
[2011-07-19 12:21:20] dav...@php.net

The following patch has been added/updated:

Patch Name: bug51939.patch
Revision:   1311092480
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51939.patch&revision=1311092480


[2010-05-28 01:40:45] mchenryc at gmail dot com

Description:

When parsing XML, PHP has no way to set a handler for general entities, though 
a 
handler can be set for unparsed entities.

Expat has deprecated the XML_SetUnparsedEntityDeclHandler in favor of 
XML_SetEntityDeclHandler, which is called for all entity types (including 
general 
and unparsed).

http://expat.cvs.sourceforge.net/viewvc/expat/expat/lib/expat.h?
revision=1.80&view=markup#l_311

PHP should add the xml_set_entity_decl_handler function to allow handling of 
all 
entity declarations.


Test script:
---
$data = ']>&generalEntity;';

function 
h_entity_decl($parser,$entity_name,$is_parameter_entity,$value,$base,$system_id,$public_id,$notation_name)
 {
echo "$entity_name - $is_parameter_entity - $value";
};

$parser = xml_parser_create();
xml_set_entity_decl_handler($parser, 'h_entity_decl');

xml_parse($parser,$data,false) or 
die (sprintf("XML Error: %s at line %d\n", 
 xml_error_string(xml_get_error_code($parser)),
 xml_get_current_line_number($parser)));
xml_parser_free($parser);


Expected result:

It should run with the following output:

generalEntity - 0 - General Entity


Actual result:
--
Fatal Error: Call to undefined function xml_set_entity_decl_handler()







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


Req #51939 [PATCH]: Add xml_set_entity_decl_handler function

2011-07-21 Thread dav...@php.net
Edit report at https://bugs.php.net/bug.php?id=51939&edit=1

 ID: 51939
 Patch added by:     dav...@php.net
 Reported by:mchenryc at gmail dot com
 Summary:Add xml_set_entity_decl_handler function
 Status: Assigned
 Type:   Feature/Change Request
 Package:XML related
 PHP Version:trunk-SVN-2010-05-28 (SVN)
 Assigned To:davidc
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: bug51939-3-ws.patch
Revision:   1311252230
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51939-3-ws.patch&revision=1311252230


Previous Comments:

[2011-07-21 08:39:38] dav...@php.net

The following patch has been added/updated:

Patch Name: bug51392-ws
Revision:   1311251978
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51392-ws&revision=1311251978


[2011-07-19 12:22:21] dav...@php.net

I've added a patch for this but I'd like to write a few more tests before 
committing it. If you could apply it and let me know if this helps you that'd 
be 
nice.

----
[2011-07-19 12:21:20] dav...@php.net

The following patch has been added/updated:

Patch Name: bug51939.patch
Revision:   1311092480
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51939.patch&revision=1311092480


[2010-05-28 01:40:45] mchenryc at gmail dot com

Description:

When parsing XML, PHP has no way to set a handler for general entities, though 
a 
handler can be set for unparsed entities.

Expat has deprecated the XML_SetUnparsedEntityDeclHandler in favor of 
XML_SetEntityDeclHandler, which is called for all entity types (including 
general 
and unparsed).

http://expat.cvs.sourceforge.net/viewvc/expat/expat/lib/expat.h?
revision=1.80&view=markup#l_311

PHP should add the xml_set_entity_decl_handler function to allow handling of 
all 
entity declarations.


Test script:
---
$data = ']>&generalEntity;';

function 
h_entity_decl($parser,$entity_name,$is_parameter_entity,$value,$base,$system_id,$public_id,$notation_name)
 {
echo "$entity_name - $is_parameter_entity - $value";
};

$parser = xml_parser_create();
xml_set_entity_decl_handler($parser, 'h_entity_decl');

xml_parse($parser,$data,false) or 
die (sprintf("XML Error: %s at line %d\n", 
 xml_error_string(xml_get_error_code($parser)),
 xml_get_current_line_number($parser)));
xml_parser_free($parser);


Expected result:

It should run with the following output:

generalEntity - 0 - General Entity


Actual result:
--
Fatal Error: Call to undefined function xml_set_entity_decl_handler()







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


Req #51939 [PATCH]: Add xml_set_entity_decl_handler function

2011-07-21 Thread dav...@php.net
Edit report at https://bugs.php.net/bug.php?id=51939&edit=1

 ID: 51939
 Patch added by:     dav...@php.net
 Reported by:mchenryc at gmail dot com
 Summary:Add xml_set_entity_decl_handler function
 Status: Assigned
 Type:   Feature/Change Request
 Package:XML related
 PHP Version:trunk-SVN-2010-05-28 (SVN)
 Assigned To:davidc
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: Bug51939.patch
Revision:   1311253426
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=Bug51939.patch&revision=1311253426


Previous Comments:

[2011-07-21 08:43:50] dav...@php.net

The following patch has been added/updated:

Patch Name: bug51939-3-ws.patch
Revision:   1311252230
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51939-3-ws.patch&revision=1311252230


[2011-07-21 08:39:38] dav...@php.net

The following patch has been added/updated:

Patch Name: bug51392-ws
Revision:   1311251978
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51392-ws&revision=1311251978

--------
[2011-07-19 12:22:21] dav...@php.net

I've added a patch for this but I'd like to write a few more tests before 
committing it. If you could apply it and let me know if this helps you that'd 
be 
nice.

--------
[2011-07-19 12:21:20] dav...@php.net

The following patch has been added/updated:

Patch Name: bug51939.patch
Revision:   1311092480
URL:
https://bugs.php.net/patch-display.php?bug=51939&patch=bug51939.patch&revision=1311092480


[2010-05-28 01:40:45] mchenryc at gmail dot com

Description:

When parsing XML, PHP has no way to set a handler for general entities, though 
a 
handler can be set for unparsed entities.

Expat has deprecated the XML_SetUnparsedEntityDeclHandler in favor of 
XML_SetEntityDeclHandler, which is called for all entity types (including 
general 
and unparsed).

http://expat.cvs.sourceforge.net/viewvc/expat/expat/lib/expat.h?
revision=1.80&view=markup#l_311

PHP should add the xml_set_entity_decl_handler function to allow handling of 
all 
entity declarations.


Test script:
---
$data = ']>&generalEntity;';

function 
h_entity_decl($parser,$entity_name,$is_parameter_entity,$value,$base,$system_id,$public_id,$notation_name)
 {
echo "$entity_name - $is_parameter_entity - $value";
};

$parser = xml_parser_create();
xml_set_entity_decl_handler($parser, 'h_entity_decl');

xml_parse($parser,$data,false) or 
die (sprintf("XML Error: %s at line %d\n", 
 xml_error_string(xml_get_error_code($parser)),
 xml_get_current_line_number($parser)));
xml_parser_free($parser);


Expected result:

It should run with the following output:

generalEntity - 0 - General Entity


Actual result:
--
Fatal Error: Call to undefined function xml_set_entity_decl_handler()







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


[PHP-BUG] Req #60128 [NEW]: Add SplClassLoader to SPL

2011-10-25 Thread dav...@php.net
From: davidc
Operating system: OSX (Irrelevant)
PHP version:  5.4SVN-2011-10-25 (SVN)
Package:  SPL related
Bug Type: Feature/Change Request
Bug description:Add SplClassLoader to SPL

Description:

As stated in this rfc: https://wiki.php.net/rfc/splclassloader we would
like to 
see the SplClassLoader (Patch linked) so that users can benefit of the PSR

without having to install an extra extension.

The initial patch was in fact an extension on its own however the newest
version 
of the patch is fitted to include it directly into SPL 
(https://gist.github.com/1310352)



-- 
Edit bug report at https://bugs.php.net/bug.php?id=60128&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=60128&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=60128&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=60128&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=60128&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=60128&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=60128&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=60128&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=60128&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=60128&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=60128&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=60128&r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=60128&r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=60128&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=60128&r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=60128&r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=60128&r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=60128&r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=60128&r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=60128&r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=60128&r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=60128&r=mysqlcfg



Req #60128 [PATCH]: Add SplClassLoader to SPL

2011-10-25 Thread dav...@php.net
Edit report at https://bugs.php.net/bug.php?id=60128&edit=1

 ID: 60128
 Patch added by:     dav...@php.net
 Reported by:    dav...@php.net
 Summary:Add SplClassLoader to SPL
 Status: Open
 Type:   Feature/Change Request
 Package:SPL related
 Operating System:   OSX (Irrelevant)
 PHP Version:5.4SVN-2011-10-25 (SVN)
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: spl-classloader
Revision:   1319537918
URL:
https://bugs.php.net/patch-display.php?bug=60128&patch=spl-classloader&revision=1319537918


Previous Comments:

[2011-10-25 10:18:18] dav...@php.net

Description:

As stated in this rfc: https://wiki.php.net/rfc/splclassloader we would like to 
see the SplClassLoader (Patch linked) so that users can benefit of the PSR 
without having to install an extra extension.

The initial patch was in fact an extension on its own however the newest 
version 
of the patch is fitted to include it directly into SPL 
(https://gist.github.com/1310352)








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