XML/DOM
HLI can dump all DOMNodes (including DOMDocument),
DOMNodeList and DOMCharacterData,
SimpleXMLElements and XML-like strings as
highlighted XML.
All examples except the last two are done with this XML document.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE root>
<root xmlns="http://www.example.org/default-namespace" xmlns:ns="http://www.example.org/prefixed-namespace">
<!-- Comment -->
<tag-1 xml:id='id-1' ns:attr-1='attrValue 1.1' attr-2='attrValue 1.2'>
<ns:subtag subattr="subtag 1"/><ns:subtag subattr="subtag 2"/><ns:subtag subattr="subtag 3"/>
</tag-1>
<?php echo 'this is a '."processing instruction"?>
<tag-2 xml:id="id-2" ns:attr-1="attrValue 2.1" attr-2="attrValue 2.2">
<ns:subtag subattr="subtag 4">
<ns:äöüßÄÖÜ description="just a node to ensure that international characters work"><![CDATA[
<Das Donaudampfschiffahrtskapitänspatent & der Titicacasee>
]]></ns:äöüßÄÖÜ>
</ns:subtag>
</tag-2>
</root>
DOMDocument
DOMDocuments are displayed as the return value of saveXML().
Additionally, the formatOutput-property is set. This may make
reading a little bit easier. Note that this value is set back to its original value after
the dump, so outputting the document yourself might not give exactly the same
result.
visit HLI#X
1. pre(DOMDocument::loadXML($xml)) type: DOMDocument (object) internal-class DOMDocument
methods
− public
compareDocumentPosition()
createProcessingInstruction()
in builder\plugins\domDump.php on line 4633 <p>
34 All examples except the last two are done with this XML document.
35 </p>
36 <div class="code"><?php echo htmlspecialchars($xml); ?></div>
37 <h3>DOMDocument</h3>
38 <p>
39 DOMDocuments are displayed as the return value of <code>saveXML()</code>.
40 Additionally, the <code>formatOutput</code>-property is set. This may make
41 reading a little bit easier. Note that this value is set back to its original value after
42 the dump, so outputting the document yourself might not give exactly the same
43 result.
44 </p>
45 <?php
46 pre(DOMDocument::loadXML($xml));
47 ?>
48 <h3>SimpleXMLElement</h3>
49 <p>
50 SimpleXMLElements are displayed as the return value of <code>asXML()</code>.
51 There is no option like <code>formatOutput</code> for SimpleXMLElements. So
52 the output is displayed without improved newlines and indentation. It is
53 planned not to use the XML dump but to walk through the nodes and do the
54 white-space formatting in HLI, but I do not work too often with SimpleXML. So
55 this has time. Note that the example is exactly the same input as in the
56 DOMDocument example.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE root>
<root xmlns="http://www.example.org/default-namespace" xmlns:ns="http://www.example.org/prefixed-namespace">
<!-- Comment -->
<tag-1 xml:id="id-1" ns:attr-1="attrValue 1.1" attr-2="attrValue 1.2">
<ns:subtag subattr="subtag 1"/><ns:subtag subattr="subtag 2"/><ns:subtag subattr="subtag 3"/>
</tag-1>
<?php echo 'this is a '."processing instruction"?>
<tag-2 xml:id="id-2" ns:attr-1="attrValue 2.1" attr-2="attrValue 2.2">
<ns:subtag subattr="subtag 4">
<ns:äöüßÄÖÜ description="just a node to ensure that international characters work"><![CDATA[
<Das Donaudampfschiffahrtskapitänspatent & der Titicacasee>
]]></ns:äöüßÄÖÜ>
</ns:subtag>
</tag-2>
</root>
/
*** global scope ***
SimpleXMLElement
SimpleXMLElements are displayed as the return value of asXML().
There is no option like formatOutput for SimpleXMLElements. So
the output is displayed without improved newlines and indentation. It is
planned not to use the XML dump but to walk through the nodes and do the
white-space formatting in HLI, but I do not work too often with SimpleXML. So
this has time. Note that the example is exactly the same input as in the
DOMDocument example.
visit HLI#X
2. pre(new SimpleXMLElement($xml)) type: SimpleXMLElement (object) internal-class SimpleXMLElement
methods
in builder\plugins\domDump.php on line 5946 pre(DOMDocument::loadXML($xml));
47 ?>
48 <h3>SimpleXMLElement</h3>
49 <p>
50 SimpleXMLElements are displayed as the return value of <code>asXML()</code>.
51 There is no option like <code>formatOutput</code> for SimpleXMLElements. So
52 the output is displayed without improved newlines and indentation. It is
53 planned not to use the XML dump but to walk through the nodes and do the
54 white-space formatting in HLI, but I do not work too often with SimpleXML. So
55 this has time. Note that the example is exactly the same input as in the
56 DOMDocument example.
57 </p>
58 <?php
59 pre(new SimpleXMLElement($xml));
60 ?>
61 <h3>DOMXPath</h3>
62 <p>
63 Passing a DOMXPath object to HLI has the same effect as passing its
64 <code>DOMXPath::$document</code> property.
65 </p>
66
67 <h3>Other DOM Elements</h3>
68 <p>
69 All DOM object will have some meaningful output.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE root>
<root xmlns="http://www.example.org/default-namespace" xmlns:ns="http://www.example.org/prefixed-namespace">
<!-- Comment -->
<tag-1 xml:id="id-1" ns:attr-1="attrValue 1.1" attr-2="attrValue 1.2">
<ns:subtag subattr="subtag 1"/><ns:subtag subattr="subtag 2"/><ns:subtag subattr="subtag 3"/>
</tag-1>
<?php echo 'this is a '."processing instruction"?>
<tag-2 xml:id="id-2" ns:attr-1="attrValue 2.1" attr-2="attrValue 2.2">
<ns:subtag subattr="subtag 4">
<ns:äöüßÄÖÜ description="just a node to ensure that international characters work"><![CDATA[
<Das Donaudampfschiffahrtskapitänspatent & der Titicacasee>
]]></ns:äöüßÄÖÜ>
</ns:subtag>
</tag-2>
</root>
/
*** global scope ***
DOMXPath
Passing a DOMXPath object to HLI has the same effect as passing its
DOMXPath::$document property.
Other DOM Elements
All DOM object will have some meaningful output.
visit HLI#X
3. pre($Doc->getElementById('id-1')) type: DOMElement (object) internal-class DOMElement
methods
− public
compareDocumentPosition()
in builder\plugins\domDump.php on line 7360 ?>
61 <h3>DOMXPath</h3>
62 <p>
63 Passing a DOMXPath object to HLI has the same effect as passing its
64 <code>DOMXPath::$document</code> property.
65 </p>
66
67 <h3>Other DOM Elements</h3>
68 <p>
69 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
<tag-1 xml:id="id-1" ns:attr-1="attrValue 1.1" attr-2="attrValue 1.2">
<ns:subtag subattr="subtag 1"/><ns:subtag subattr="subtag 2"/><ns:subtag subattr="subtag 3"/>
</tag-1>
/
*** global scope ***
visit HLI#X
4. pre($Doc->getElementsByTagName('subtag')) type: DOMNodeList (object) internal-class DOMNodeList
methods
in builder\plugins\domDump.php on line 7461 <h3>DOMXPath</h3>
62 <p>
63 Passing a DOMXPath object to HLI has the same effect as passing its
64 <code>DOMXPath::$document</code> property.
65 </p>
66
67 <h3>Other DOM Elements</h3>
68 <p>
69 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
<ns:subtag xmlns:ns="http://www.example.org/prefixed-namespace" subattr="subtag 1"/>
<ns:subtag xmlns:ns="http://www.example.org/prefixed-namespace" subattr="subtag 2"/>
<ns:subtag xmlns:ns="http://www.example.org/prefixed-namespace" subattr="subtag 3"/>
<ns:subtag xmlns:ns="http://www.example.org/prefixed-namespace" subattr="subtag 4">
<ns:äöüßÄÖÜ description="just a node to ensure that international characters work"><![CDATA[
<Das Donaudampfschiffahrtskapitänspatent & der Titicacasee>
]]></ns:äöüßÄÖÜ>
</ns:subtag>
/
*** global scope ***
visit HLI#X
5. pre($Path->query('//@*[substring-[…]) type: DOMNodeList (object) internal-class DOMNodeList
methods
in builder\plugins\domDump.php on line 7865 </p>
66
67 <h3>Other DOM Elements</h3>
68 <p>
69 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
ns:attr-1="attrValue 1.1"
attr-2="attrValue 1.2"
ns:attr-1="attrValue 2.1"
attr-2="attrValue 2.2"
/
*** global scope ***
visit HLI#X
6. pre($Path->query('//dn:tag-1')->i[…]) type: DOMNamedNodeMap (object) internal-class DOMNamedNodeMap
methods
in builder\plugins\domDump.php on line 7966
67 <h3>Other DOM Elements</h3>
68 <p>
69 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
xml:id="id-1"
ns:attr-1="attrValue 1.1"
attr-2="attrValue 1.2"
/
*** global scope ***
visit HLI#X
7. pre($Doc->getElementsByTagName('t[…]) type: DOMAttr (object)methods
− public
compareDocumentPosition()
in builder\plugins\domDump.php on line 8067 <h3>Other DOM Elements</h3>
68 <p>
69 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
90 guess if something should be highlighted as XML. Currently, the rule is that
xml:id="id-1"
/
*** global scope ***
visit HLI#X
8. pre($Doc->documentElement->childN[…]) type: DOMComment (object) internal-class DOMComment
methods
− public
compareDocumentPosition()
in builder\plugins\domDump.php on line 8168 <p>
69 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
90 guess if something should be highlighted as XML. Currently, the rule is that
91 the trimmed string must start with a left angle bracket, end with a right
<!-- Comment -->
/
*** global scope ***
visit HLI#X
9. pre($Doc->documentElement->childN[…]) type: DOMProcessingInstruction (object) internal-class DOMProcessingInstruction
methods
− public
compareDocumentPosition()
in builder\plugins\domDump.php on line 8269 All DOM object will have some meaningful output.
70 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
90 guess if something should be highlighted as XML. Currently, the rule is that
91 the trimmed string must start with a left angle bracket, end with a right
92 angle bracket and have at least one character whatsoever in between them.
<?php echo 'this is a '."processing instruction" ?>
/
*** global scope ***
visit HLI#X
10. pre($Doc->documentElement->childN[…]) type: DOMCdataSection (object) internal-class DOMCdataSection
methods
− public
compareDocumentPosition()
isElementContentWhitespace()
isWhitespaceInElementContent()
in builder\plugins\domDump.php on line 8370 </p>
71 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
90 guess if something should be highlighted as XML. Currently, the rule is that
91 the trimmed string must start with a left angle bracket, end with a right
92 angle bracket and have at least one character whatsoever in between them.
93 I haven't had one single dump where this guess was wrong, but it is not
<![CDATA[
<Das Donaudampfschiffahrtskapitänspatent & der Titicacasee>
]]>
/
*** global scope ***
visit HLI#X
11. pre($Doc->doctype) type: DOMDocumentType (object) internal-class DOMDocumentType
methods
− public
compareDocumentPosition()
in builder\plugins\domDump.php on line 8471 <?php
72 $Doc = DOMDocument::loadXML($xml);
73 pre($Doc->getElementById('id-1'));
74 pre($Doc->getElementsByTagName('subtag'));
75 $Path = new DOMXPath($Doc);
76 $Path->registerNamespace('dn','http://www.example.org/default-namespace');
77 $Path->registerNamespace('pn','http://www.example.org/prefixed-namespace');
78 pre($Path->query('//@*[substring-before(local-name(),"-") = "attr"]'));
79 pre($Path->query('//dn:tag-1')->item(0)->attributes);
80 pre($Doc->getElementsByTagName('tag-1')->item(0)->attributes->item(0));
81 pre($Doc->documentElement->childNodes->item(1));
82 pre($Doc->documentElement->childNodes->item(5));
83 pre($Doc->documentElement->childNodes->item(7)->childNodes->item(1)->childNodes->item(1)->childNodes->item(0));
84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
90 guess if something should be highlighted as XML. Currently, the rule is that
91 the trimmed string must start with a left angle bracket, end with a right
92 angle bracket and have at least one character whatsoever in between them.
93 I haven't had one single dump where this guess was wrong, but it is not
94 onehundredpercent. The example is the HTML-code of the start page.
<!DOCTYPE root>
/
*** global scope ***
XML-like Strings
If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
highlight that, too. The problem with such a feature is naturally how to
guess if something should be highlighted as XML. Currently, the rule is that
the trimmed string must start with a left angle bracket, end with a right
angle bracket and have at least one character whatsoever in between them.
I haven't had one single dump where this guess was wrong, but it is not
onehundredpercent. The example is the HTML-code of the start page.
visit HLI#X
12. pre(file_get_contents('http://'.$[…]) type: string
in builder\plugins\domDump.php on line 97 84 pre($Doc->doctype);
85 ?>
86 <h3>XML-like Strings</h3>
87 <p>
88 If the DOM/XML-plugin thinks that you are dumping an XML-string, it will
89 highlight that, too. The problem with such a feature is naturally how to
90 guess if something should be highlighted as XML. Currently, the rule is that
91 the trimmed string must start with a left angle bracket, end with a right
92 angle bracket and have at least one character whatsoever in between them.
93 I haven't had one single dump where this guess was wrong, but it is not
94 onehundredpercent. The example is the HTML-code of the start page.
95 </p>
96 <?php
97 pre(file_get_contents('http://'.$_SERVER['HTTP_HOST'].dirname(dirname($_SERVER['SCRIPT_NAME']))));
98 ?>
99 <h3>HTML</h3>
100 <p>
101 As libxml supports loading of HTML, too, you can dump it with HLI. There is
102 no difference in the passed object. However, PHP (or libxml) doesn't do a
103 very good job in getting the <code>saveXML()</code> right. This 100% valid
104 page is messed up in some way: Note the second XML-processing instruction
105 (even with one additional question mark at the end) and the second XML-namespace
106 in the opening html-tag. Also it forces non-ascii characters to be displayed
107 as unicode-entities, not as html-entities as one would expect.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="content-type" content="text/html; encoding=UTF-8"/>
<title>HLI: Home</title>
<link rel="stylesheet" href="./screen.css" type="text/css" media="screen"/>
<link rel="stylesheet" href="./print.css" type="text/css" media="print"/>
<!--<script type="text/javascript" src="/firebug/firebug.js"></script>-->
</head>
<body>
<div id="menu">
<h2>HLI</h2>
<ul>
<li><a href="././index.php">Home</a></li>
<li><a href="././download.php">Download</a></li>
<li><a href="././intro.php">Introduction</a></li>
<li><a href="././features/index.php">Basic Features</a>
<ul>
<li><a href="././features/usage.php">Usage</a></li>
<li><a href="././features/theWindow.php">The Dump Window</a></li>
<li><a href="././features/simpleDumps.php">Simple Dumps</a></li>
<li><a href="././features/backtrace.php">Backtrace</a></li>
</ul>
</li>
<li><a href="././plugins/index.php">Dumpers</a>
<ul>
<li><a href="././plugins/arrayDump.php">Arrays</a></li>
<li><a href="././plugins/objectDump.php">Objects</a></li>
<li><a href="././plugins/imageDump.php">GD Images</a></li>
<li><a href="././plugins/serializedDump.php">Serialized Strings</a></li>
<li><a href="././plugins/dbDump.php">Database</a></li>
<li><a href="././plugins/dirDump.php">Directory</a></li>
<li><a href="././plugins/domDump.php">XML/DOM</a></li>
</ul>
</li>
<li><a href="././requirements.php">Requirements</a></li>
<li><a href="././config/index.php">Installing</a>
<ul>
<li><a href="././config/config.php">Configuration</a></li>
</ul>
</li>
<li><a href="././contrib.php">Contributing</a></li>
</ul>
</div>
<div id="content">
<h2>Home</h2><div id="news">
<h3>News</h3>
<h4>
<em>2007-03-29</em> <strong>0.1.5</strong>
</h4>
<p>
This release makes array and object dump <strong>10% faster</strong>.
</p>
<p>
To give you some more news: I'm working on <strong>0.2</strong> and it will bring something like an <strong>observer</strong> and ajax-stuff, including an online <strong>configuration</strong> tool. I'm trying hard that it still works out of the box. [Of course that is only true if there is no conflict with the platform you are working on. If you have trouble in some environment, please <a href="mailto:thc@forestfactory.de">let me know</a>.]
</p>
<h4>
<em>2007-03-17</em> <strong>Ok, another one</strong>
</h4>
<p>
<strong>Release 0.1.4</strong> is ready, and this one <em>should</em> be the last before 0.2 – unless I find any sore bugs. I implemented a better support for <a href="plugins/dbDump">Databases</a> and fixed some other issues.
</p>
<p>
HLI was never meant to become such a big project, and the code looks <q xml:lang="de_BY">wia Kraut und Rüam</q> as we say in Bavaria (<a href="http://dict.leo.org/ende?search=wie+Kraut+und+R%FCben">LEO</a> translates this as <q>higgledy-piggledy</q>). So now it is time to do some restructuring and re-implementation. API's will change and everything will become more flexible.
</p>
<p>
This will take some time, so don't hold your breath.
</p>
<!-- <p>
Oh, and I found a usage for <code>text-decoration:blink</code> (beside <q>Schrödingers cat is <span style="text-decoration:blink">not</span> dead</q>). Look for it on this site ...
</p> -->
<h4>
<em>2007-03-14</em> <strong>Version 0.1.3 released</strong>
</h4>
<p>
Fixes the issues mentioned in the last news entry.
</p>
<h4>
<em>2007-03-13</em> <strong>I'm sorry!</strong>
</h4>
<p>
There are some bugs in the version released tonight that I will fix during the up-coming night: Free positioned dump windows do not have a maximum height; mysqli-dumps display XML-tags when a result field is empty; and some more. Version 0.1.3 will be available tomorrow, so if you do not have a good reason for updating to 0.1.2, you should wait. Sorry for that.
</p>
<h4>
<em>2007-03-13</em> <strong>Version 0.1.2 released</strong>
</h4>
<p>
Lots of bug fixes and improvements. Got to <a href="download">downloads</a> for a full changelog.
</p>
<h4>
<em>2007-03-10</em> <strong>Workaround for XDebug-issue comming soon</strong>
</h4>
<p>
If nothing bad is happening the next release will be ready in the early morning (UTC) of monday 2007-03-12.
</p>
<p>
I think that it is not possible to parse the <code>var_dump()</code> printed by <a href="http://www.xdebug.org/">XDebug</a> in a usefull way (and working with more than just one version of XDebug). A temporally workaround is to display the unmodified dump of XDebug inside HLI. This has the drawback that highlighting colors are inconsistent and some features like folding are not working. I've written to the developers of XDebug for a way to fix this and to get access to the original PHP <code>var_dump()</code> function.
</p>
<p>
Next release will also fix the missing backtrace if using <code>ifpre()</code> or <code>ifex()</code>, will bring static properties (except for the value of private ones), reduce created code size and many more improvements.
</p>
<h4>
<em>2007-03-06</em> <strong>New version 0.1.1 works with Firefox 1.5 and Opera 9.10</strong>
</h4>
<p>
A javascript issue was found and fixed, so the new release work both on Firefox 1.5 and Opera 9.10. Note that the XDebug issue has NOT been fixed yet.
</p>
<h4>
<em>2007-03-06</em> <strong>Problems with XDebug</strong>
</h4>
<p>
Thanks to my <a href="http://cmr.cx">brother</a>, HLI has been tested on some environments I do not have easy access to (or do not have the time to think about). So HLI does not work in combination with <a href="http://www.xdebug.org/">XDebug</a>. The reason is that XDebug changes the way <code>var_dump()</code> works. <code>var_dump()</code> is used in the Recursive Plugin and is parsed and eval'd (as this was the only way to get private properties in PHP 5.2 and avoid infinit recursions). I'll have to write an alternate parser for the var_dump of XDebug. This may take some time.
</p>
<h4>
<em>2007-03-06</em> <strong>I just heard that there are still problems with HLI.</strong>
</h4>
<p>
While I am not surprised, I thank you for every good bug report. To be helpful it would be best if you write an <a href="mailto:thc@forestfactory.de">email</a> including the function call you did and a <code>var_dump()</code> or <code>print_r()</code> of that variable you dumped. Please also provide system information like operating system, PHP version, Apache Version. It wouln't be overdoing it if you sent me a <code>phpinfo()</code> file.
</p>
<h4>
<em>2007-03-06</em> <strong>Initial Release 0.1</strong>
</h4>
<p>
Maybe this is a little bit quick done, but I cannot wait to get it to the people.
</p>
</div>
<!-- :mode=xml: -->
<p>
<acronym title="Have a Look at It">HLI</acronym> <small>[ˈheɪːli]</small> is a
variable inspector written for and in PHP 5. Its purpose is to replace <code>var_dump()</code>
and give you as much useful information about a variable as possible.
</p>
<p>Get <a href="download.php">current Release</a>!</p>
<dl>
<dt>Works with most page layouts</dt>
<dd>
HLI uses (almost) only <code>div</code> and <code>span</code> with inline CSS
to make sure that it is displayed correctly inside your project.
</dd>
<dt>Recursive Dumps</dt>
<dd>
With only one little function you get
<strong>all values highlighted</strong> from any variable.
</dd>
<dt>API's and Documentation</dt>
<dd>
Get access to the full <strong>API of any class</strong>. If it is your own code, you will
also see <a href="http://www.phpdoc.org">PHPDocumentor</a> <strong>documentation</strong>
and <strong>function source code</strong>.
</dd>
<dt>Know Where You Are</dt>
<dd>
HLI prints a <strong>backtrace</strong> for every dump. However, it makes sure you don't get
more information than you need. <strong>Type-highlighted arguments</strong> will be
shortened as needed to get a quick overview and make parameters
distinguishable. Furthermore HLI will cut off common project paths
automatically or configureably. So you see only the path information you
need. If you want to take a quick look at the
<strong>code surrounding a breakpoint</strong>, HLI has it right there.
</dd>
<dt>Plugin Support</dt>
<dd>
Without dump plugins, HLI will display a counterpart to a simple <code>(string)</code>
conversion of the value. But with plugins it may <strong>dump anything</strong> in an appropriated
way. At the moment of writing, HLI already comes with Plugins for
<strong>XML/DOM</strong>, <strong>SimpleXML</strong>, <strong>MySQL/MySQLi</strong>, <strong>PDO</strong>,
<strong>directory resources/objects</strong>, <strong>gd-resources</strong>
and <strong>serialized strings</strong>.
</dd>
<dt>Valid XHTML</dt>
<dd>
Throw any variable or literal value in, and you get a full dump in
nicely formatted <strong>valid XHTML</strong>. HLI will not destroy the
validity of your page – if it would be valid without HLI – and
you do the dump at a place where a block-level element is allowed.
</dd>
</dl>
</div>
<div id="foot"><small>build exec time: 8.91 ms</small><small></small> 2007-03-29 01:15:13 © 2007 Thomas Forster <<a href="mailto:thc@forestfactory.de">thc@forestfactory.de</a>>
</div>
</body>
</html>
/
*** global scope ***
HTML
As libxml supports loading of HTML, too, you can dump it with HLI. There is
no difference in the passed object. However, PHP (or libxml) doesn't do a
very good job in getting the saveXML() right. This 100% valid
page is messed up in some way: Note the second XML-processing instruction
(even with one additional question mark at the end) and the second XML-namespace
in the opening html-tag. Also it forces non-ascii characters to be displayed
as unicode-entities, not as html-entities as one would expect.
Actually it does a better job if you use saveHTML() instead,
but as it also is not really correct I have not implemented it yet.
visit HLI#X
13. pre(DOMDocument::loadHTMLFile('ht[…]) type: DOMDocument (object) internal-class DOMDocument
methods
− public
compareDocumentPosition()
createProcessingInstruction()
in builder\plugins\domDump.php on line 114101 As libxml supports loading of HTML, too, you can dump it with HLI. There is
102 no difference in the passed object. However, PHP (or libxml) doesn't do a
103 very good job in getting the <code>saveXML()</code> right. This 100% valid
104 page is messed up in some way: Note the second XML-processing instruction
105 (even with one additional question mark at the end) and the second XML-namespace
106 in the opening html-tag. Also it forces non-ascii characters to be displayed
107 as unicode-entities, not as html-entities as one would expect.
108 </p>
109 <p>
110 Actually it does a better job if you use <code>saveHTML()</code> instead,
111 but as it also is not really correct I have not implemented it yet.
112 </p>
113 <?php
114 pre(DOMDocument::loadHTMLFile('http://'.$_SERVER['HTTP_HOST'].dirname(dirname($_SERVER['SCRIPT_NAME']))));
115 ?>
116 <?php
117 echo foot()
118 ?>
<?xml version="1.0" standalone="yes"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<?xml version="1.0" encoding="UTF-8"??>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="content-type" content="text/html; encoding=UTF-8"/>
<title>HLI: Home</title>
<link rel="stylesheet" href="./screen.css" type="text/css" media="screen"/>
<link rel="stylesheet" href="./print.css" type="text/css" media="print"/>
<!--<script type="text/javascript" src="/firebug/firebug.js"></script>-->
</head>
<body>
<div id="menu">
<h2>HLI</h2>
<ul><li><a href="././index.php">Home</a></li>
<li><a href="././download.php">Download</a></li>
<li><a href="././intro.php">Introduction</a></li>
<li><a href="././features/index.php">Basic Features</a>
<ul><li><a href="././features/usage.php">Usage</a></li>
<li><a href="././features/theWindow.php">The Dump Window</a></li>
<li><a href="././features/simpleDumps.php">Simple Dumps</a></li>
<li><a href="././features/backtrace.php">Backtrace</a></li>
</ul></li>
<li><a href="././plugins/index.php">Dumpers</a>
<ul><li><a href="././plugins/arrayDump.php">Arrays</a></li>
<li><a href="././plugins/objectDump.php">Objects</a></li>
<li><a href="././plugins/imageDump.php">GD Images</a></li>
<li><a href="././plugins/serializedDump.php">Serialized Strings</a></li>
<li><a href="././plugins/dbDump.php">Database</a></li>
<li><a href="././plugins/dirDump.php">Directory</a></li>
<li><a href="././plugins/domDump.php">XML/DOM</a></li>
</ul></li>
<li><a href="././requirements.php">Requirements</a></li>
<li><a href="././config/index.php">Installing</a>
<ul><li><a href="././config/config.php">Configuration</a></li>
</ul></li>
<li><a href="././contrib.php">Contributing</a></li>
</ul></div>
<div id="content">
<h2>Home</h2><div id="news">
<h3>News</h3>
<h4>
<em>2007-03-29</em> <strong>0.1.5</strong>
</h4>
<p>
This release makes array and object dump <strong>10% faster</strong>.
</p>
<p>
To give you some more news: I'm working on <strong>0.2</strong> and it will bring something like an <strong>observer</strong> and ajax-stuff, including an online <strong>configuration</strong> tool. I'm trying hard that it still works out of the box. [Of course that is only true if there is no conflict with the platform you are working on. If you have trouble in some environment, please <a href="mailto:thc@forestfactory.de">let me know</a>.]
</p>
<h4>
<em>2007-03-17</em> <strong>Ok, another one</strong>
</h4>
<p>
<strong>Release 0.1.4</strong> is ready, and this one <em>should</em> be the last before 0.2 – unless I find any sore bugs. I implemented a better support for <a href="plugins/dbDump">Databases</a> and fixed some other issues.
</p>
<p>
HLI was never meant to become such a big project, and the code looks <q xml:lang="de_BY" lang="de_BY">wia Kraut und Rüam</q> as we say in Bavaria (<a href="http://dict.leo.org/ende?search=wie+Kraut+und+R%FCben">LEO</a> translates this as <q>higgledy-piggledy</q>). So now it is time to do some restructuring and re-implementation. API's will change and everything will become more flexible.
</p>
<p>
This will take some time, so don't hold your breath.
</p>
<!-- <p>
Oh, and I found a usage for <code>text-decoration:blink</code> (beside <q>Schrödingers cat is <span style="text-decoration:blink">not</span> dead</q>). Look for it on this site ...
</p> -->
<h4>
<em>2007-03-14</em> <strong>Version 0.1.3 released</strong>
</h4>
<p>
Fixes the issues mentioned in the last news entry.
</p>
<h4>
<em>2007-03-13</em> <strong>I'm sorry!</strong>
</h4>
<p>
There are some bugs in the version released tonight that I will fix during the up-coming night: Free positioned dump windows do not have a maximum height; mysqli-dumps display XML-tags when a result field is empty; and some more. Version 0.1.3 will be available tomorrow, so if you do not have a good reason for updating to 0.1.2, you should wait. Sorry for that.
</p>
<h4>
<em>2007-03-13</em> <strong>Version 0.1.2 released</strong>
</h4>
<p>
Lots of bug fixes and improvements. Got to <a href="download">downloads</a> for a full changelog.
</p>
<h4>
<em>2007-03-10</em> <strong>Workaround for XDebug-issue comming soon</strong>
</h4>
<p>
If nothing bad is happening the next release will be ready in the early morning (UTC) of monday 2007-03-12.
</p>
<p>
I think that it is not possible to parse the <code>var_dump()</code> printed by <a href="http://www.xdebug.org/">XDebug</a> in a usefull way (and working with more than just one version of XDebug). A temporally workaround is to display the unmodified dump of XDebug inside HLI. This has the drawback that highlighting colors are inconsistent and some features like folding are not working. I've written to the developers of XDebug for a way to fix this and to get access to the original PHP <code>var_dump()</code> function.
</p>
<p>
Next release will also fix the missing backtrace if using <code>ifpre()</code> or <code>ifex()</code>, will bring static properties (except for the value of private ones), reduce created code size and many more improvements.
</p>
<h4>
<em>2007-03-06</em> <strong>New version 0.1.1 works with Firefox 1.5 and Opera 9.10</strong>
</h4>
<p>
A javascript issue was found and fixed, so the new release work both on Firefox 1.5 and Opera 9.10. Note that the XDebug issue has NOT been fixed yet.
</p>
<h4>
<em>2007-03-06</em> <strong>Problems with XDebug</strong>
</h4>
<p>
Thanks to my <a href="http://cmr.cx">brother</a>, HLI has been tested on some environments I do not have easy access to (or do not have the time to think about). So HLI does not work in combination with <a href="http://www.xdebug.org/">XDebug</a>. The reason is that XDebug changes the way <code>var_dump()</code> works. <code>var_dump()</code> is used in the Recursive Plugin and is parsed and eval'd (as this was the only way to get private properties in PHP 5.2 and avoid infinit recursions). I'll have to write an alternate parser for the var_dump of XDebug. This may take some time.
</p>
<h4>
<em>2007-03-06</em> <strong>I just heard that there are still problems with HLI.</strong>
</h4>
<p>
While I am not surprised, I thank you for every good bug report. To be helpful it would be best if you write an <a href="mailto:thc@forestfactory.de">email</a> including the function call you did and a <code>var_dump()</code> or <code>print_r()</code> of that variable you dumped. Please also provide system information like operating system, PHP version, Apache Version. It wouln't be overdoing it if you sent me a <code>phpinfo()</code> file.
</p>
<h4>
<em>2007-03-06</em> <strong>Initial Release 0.1</strong>
</h4>
<p>
Maybe this is a little bit quick done, but I cannot wait to get it to the people.
</p>
</div>
<!-- :mode=xml: -->
<p>
<acronym title="Have a Look at It">HLI</acronym> <small>[ˈheɪːli]</small> is a
variable inspector written for and in PHP 5. Its purpose is to replace <code>var_dump()</code>
and give you as much useful information about a variable as possible.
</p>
<p>Get <a href="download.php">current Release</a>!</p>
<dl><dt>Works with most page layouts</dt>
<dd>
HLI uses (almost) only <code>div</code> and <code>span</code> with inline CSS
to make sure that it is displayed correctly inside your project.
</dd>
<dt>Recursive Dumps</dt>
<dd>
With only one little function you get
<strong>all values highlighted</strong> from any variable.
</dd>
<dt>API's and Documentation</dt>
<dd>
Get access to the full <strong>API of any class</strong>. If it is your own code, you will
also see <a href="http://www.phpdoc.org">PHPDocumentor</a> <strong>documentation</strong>
and <strong>function source code</strong>.
</dd>
<dt>Know Where You Are</dt>
<dd>
HLI prints a <strong>backtrace</strong> for every dump. However, it makes sure you don't get
more information than you need. <strong>Type-highlighted arguments</strong> will be
shortened as needed to get a quick overview and make parameters
distinguishable. Furthermore HLI will cut off common project paths
automatically or configureably. So you see only the path information you
need. If you want to take a quick look at the
<strong>code surrounding a breakpoint</strong>, HLI has it right there.
</dd>
<dt>Plugin Support</dt>
<dd>
Without dump plugins, HLI will display a counterpart to a simple <code>(string)</code>
conversion of the value. But with plugins it may <strong>dump anything</strong> in an appropriated
way. At the moment of writing, HLI already comes with Plugins for
<strong>XML/DOM</strong>, <strong>SimpleXML</strong>, <strong>MySQL/MySQLi</strong>, <strong>PDO</strong>,
<strong>directory resources/objects</strong>, <strong>gd-resources</strong>
and <strong>serialized strings</strong>.
</dd>
<dt>Valid XHTML</dt>
<dd>
Throw any variable or literal value in, and you get a full dump in
nicely formatted <strong>valid XHTML</strong>. HLI will not destroy the
validity of your page – if it would be valid without HLI – and
you do the dump at a place where a block-level element is allowed.
</dd>
</dl></div>
<div id="foot"><small>build exec time: 5.79 ms</small><small></small> 2007-03-29 01:15:13 © 2007 Thomas Forster <<a href="mailto:thc@forestfactory.de">thc@forestfactory.de</a>>
</div>
</body>
</html>
/
*** global scope ***