#29911 [NEW]: DOMDocuments are always equal.

From: Date: Tue, 31 Aug 2004 10:59:55 +0000
Subject: #29911 [NEW]: DOMDocuments are always equal.
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-65501@lists.php.net to get a copy of this message
From: wb at pro-net dot co dot uk Operating system: FreeBSD 5.2.1 PHP version: 5.0.1 PHP Bug Type: DOM XML related Bug description: DOMDocuments are always equal. Description: ------------ Different DOMDocuments are always equal even if the 'XML' is different. Reproduce code: --------------- <?php $dom1 = new DOMDocument(); $dom1->loadXML("<root><node/></root>"); $dom2 = new DOMDocument(); $dom2->loadXML("<root><node/></root>"); $dom3 = new DOMDocument(); $dom3->loadXML("<root><node type=\"blah\"/></root>"); if($dom1 == $dom2){ print("dom1 == dom2\n"); }else{ print("dom1 != dom2\n"); } if($dom1 == $dom3){ print("dom1 == dom3\n"); }else{ print("dom1 != dom3\n"); } ?> Expected result: ---------------- dom1 == dom2 dom1 != dom3 Actual result: -------------- dom1 == dom2 dom1 == dom3 -- Edit bug report at http://bugs.php.net/?id=29911&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=29911&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=29911&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=29911&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=29911&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=29911&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=29911&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=29911&r=needscript Try newer version: http://bugs.php.net/fix.php?id=29911&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=29911&r=support Expected behavior: http://bugs.php.net/fix.php?id=29911&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=29911&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=29911&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=29911&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=29911&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=29911&r=dst IIS Stability: http://bugs.php.net/fix.php?id=29911&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=29911&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=29911&r=float

« previous php.bugs (#65501) next »