The Dom\Document class
This is the modern, spec-compliant equivalent of DOMDocument. It is the base class for Dom\XMLDocument and Dom\HTMLDocument.
This is the modern, spec-compliant equivalent of DOMDocument. It is the base class for Dom\XMLDocument and Dom\HTMLDocument.
Class synopsis
Properties
URLEquivalent to
documentURI.characterSetThe encoding of the document used for serialization. Upon parsing a document, this is set to the input encoding of that document.
inputEncodingLegacy alias for
characterSet.charsetLegacy alias for
characterSet.documentElementThe
Dom\Elementthat is the document element. This evaluates to null for document without elements.bodyThe first child of the
htmlelement that is either abodytag or aframesettag. These need to be in the HTML namespace. If no element matches, this evaluates to null.headThe first
headelement that is a child of thehtmlelement. These need to be in the HTML namespace. If no element matches, this evaluates to null.titleThe title of the document as set by the
titleelement for HTML or the SVGtitleelement for SVG. If there is no title, this evaluates to the empty string.