|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #52375 implement missing constructors in dom classes
Submitted: 2010-07-19 08:12 UTC Modified: 2010-07-19 08:22 UTC
From: giorgio dot liscio at email dot it Assigned:
Status: Not a bug Package: DOM XML related
PHP Version: 5.3.2 OS: all
Private report: No CVE-ID: None
 [2010-07-19 08:12 UTC] giorgio dot liscio at email dot it
hi, for example DOMCharacterData has no constructor
the only way i can create an instance is using a document instance

in plus php throws 

Warning: main() [function.main]: Invalid State Error in .....

some of missing constructors are

new DOMCharacterData
new DOMDocumentFragment
new DOMDocumentType


thank you for this lib, i hope to help you finding bugs



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2010-07-19 08:22 UTC]
-Status: Open +Status: Bogus
 [2010-07-19 08:22 UTC]
This is intentional: the underlying library (libxml2) requires those
objects to be attached to a document instance, and the
DOMDocument::create* methods are also the ones specified in the DOM
standard as the way to create those particular objects.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sat Jul 31 07:01:23 2021 UTC