1<?php
2function dumpElement(DOM\Element $element) {
3    echo "tagName: ", var_dump($element->tagName);
4    echo "nodeName: ", var_dump($element->nodeName);
5    echo "textContent: ", var_dump($element->textContent);
6    echo "prefix: ", var_dump($element->prefix);
7    echo "namespaceURI: ", var_dump($element->namespaceURI);
8    echo $element->ownerDocument->saveHTML($element), "\n\n";
9}
10