public function OutputRules::document in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/masterminds/html5/src/HTML5/Serializer/OutputRules.php \Masterminds\HTML5\Serializer\OutputRules::document()
Write a document element (\DOMDocument).
Instead of returning the result write it to the output stream ($output) that was passed into the constructor.
Parameters
\DOMDocument $dom:
Overrides RulesInterface::document
File
- vendor/
masterminds/ html5/ src/ HTML5/ Serializer/ OutputRules.php, line 184 - The rules for generating output in the serializer.
Class
- OutputRules
- Generate the output html5 based on element rules.
Namespace
Masterminds\HTML5\SerializerCode
public function document($dom) {
$this
->doctype();
if ($dom->documentElement) {
$this->traverser
->node($dom->documentElement);
$this
->nl();
}
}