Lines Matching refs:node
23 function print_node($node)
25 print "Node Name: " . $node->nodeName;
26 print "\nNode Type: " . $node->nodeType;
27 if ($node->nodeType != 3) {
28 $child_count = $node->childNodes->length;
34 if (strlen(trim($node->nodeValue))) {
35 print "\nNode Content: " . $node->nodeValue;
45 foreach($nodelist as $node)
47 print_node($node);
51 function print_node_compact($node, $spaces)
53 if ($node->nodeType == 3) {
54 print str_repeat(" ", $spaces) . trim($node->nodeValue) . "\n";
56 print str_repeat(" ", $spaces) . "<" . $node->nodeName . ">\n";
57 print_node_list_compact($node->childNodes, $spaces + 2);
58 print str_repeat(" ", $spaces) . "</" . $node->nodeName . ">\n";
64 foreach ($nodelist as $node) {
65 print_node_compact($node, $spaces);