php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #46849 Cloning DOMDocument doesn't clone the properties
Submitted: 2008-12-12 14:01 UTC Modified: 2008-12-16 12:55 UTC
From: hannes dot magnusson at gmail dot com Assigned: rrichards (profile)
Status: Closed Package: DOM XML related
PHP Version: 5.3.0alpha3 OS: Linux
Private report: No CVE-ID: None
 [2008-12-12 14:01 UTC] hannes dot magnusson at gmail dot com
Description:
------------
Cloning and DOMDocument doesn't clone the properties

Reproduce code:
---------------
<?php
$dom = new DOMDocument;
$dom->formatOutput = 1;
var_dump($dom->formatOutput);

$dom2 = clone $dom;
var_dump($dom2->formatOutput);


Expected result:
----------------
bool(true)
bool(true)

Actual result:
--------------
bool(true)
bool(false)

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-12-16 12:55 UTC] rrichards@php.net
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
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Mar 19 04:01:31 2024 UTC