|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #39035 Compatibilty issue between DOM and zend.ze1_compatibility_mode?
Submitted: 2006-10-04 10:46 UTC Modified: 2006-10-04 12:05 UTC
From: email_ylb-php at yahoo dot fr Assigned:
Status: Closed Package: PHP options/info functions
PHP Version: 5.1.6 OS: Windows 2003 server
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
45 - 32 = ?
Subscribe to this entry?

 [2006-10-04 10:46 UTC] email_ylb-php at yahoo dot fr
For my developments, I need to turn on the PHP option "zend.ze1_compatibility_mode". However when using DOM classes from PHP5, I am unable to get references to some properties (e.g. documentElement) of a DOMDocument object (see example below). 

Is it inappropriate to use DOM classes with this option? If so, I appologize for my post.

Reproduce code:
$doc =& new DOMDocument(); 
$success = $doc->load($inputFile);
$root =& $doc->documentElement;

echo("With \$root, the root element is " . $root->nodeName . ".<br />");
echo("With \$doc, the root element is " .$doc->documentElement->nodeName . ".<br />");

Expected result:
With $root, the root element is myRootNode.
With $doc, the root element is myRootNode.

Actual result:
With $root, the root element is .
With $doc, the root element is myRootNode.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2006-10-04 11:26 UTC]
I don't think anybody is willing to work on ze1_compatibility_mode, because it is supposed to be dropped in the nearest future.
 [2006-10-04 12:05 UTC]
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
Thank you for the report, and for helping us make PHP better.

fixed as it was a cut/paste error
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun Sep 19 00:03:39 2021 UTC