This fixes bug #36452.
Change-Id: I0fc65af8c561b23daa5301a00706acb5b3f619dc
<tag></tag>
!! result
<pre>
-string(0) ""
-array(0) {
-}
+''
+array (
+)
</pre>
!! end
!! result
<pre>
NULL
-array(0) {
-}
+array (
+)
</pre>
!! end
!! result
<pre>
NULL
-array(0) {
-}
+array (
+)
</pre>
!! end
<tag>input</tag>
!! result
<pre>
-string(5) "input"
-array(0) {
-}
+'input'
+array (
+)
</pre>
!! end
<TAG>input</TAG>
!! result
<pre>
-string(5) "input"
-array(0) {
-}
+'input'
+array (
+)
</pre>
!! end
<TaG>input</TAg>
!! result
<pre>
-string(5) "input"
-array(0) {
-}
+'input'
+array (
+)
</pre>
!! end
<tag><tag></tag></tag>
!! result
<pre>
-string(5) "<tag>"
-array(0) {
-}
+'<tag>'
+array (
+)
</pre></tag>
!! end
<tag width=200 height = "100" depth = '50' square></tag>
!! result
<pre>
-string(0) ""
-array(4) {
- ["width"]=>
- string(3) "200"
- ["height"]=>
- string(3) "100"
- ["depth"]=>
- string(2) "50"
- ["square"]=>
- string(6) "square"
-}
+''
+array (
+ 'width' => '200',
+ 'height' => '100',
+ 'depth' => '50',
+ 'square' => 'square',
+)
</pre>
!! end
<tag filename='/tmp/bla'></tag>
!! result
<pre>
-string(0) ""
-array(1) {
- ["filename"]=>
- string(8) "/tmp/bla"
-}
+''
+array (
+ 'filename' => '/tmp/bla',
+)
</pre>
!! end
!! result
<pre>
NULL
-array(1) {
- ["foo"]=>
- string(3) "bar"
-}
+array (
+ 'foo' => 'bar',
+)
</pre>text
!! end
!! result
<pre>
NULL
-array(4) {
- ["width"]=>
- string(3) "200"
- ["height"]=>
- string(3) "100"
- ["depth"]=>
- string(2) "50"
- ["square"]=>
- string(6) "square"
-}
+array (
+ 'width' => '200',
+ 'height' => '100',
+ 'depth' => '50',
+ 'square' => 'square',
+)
</pre>
<p>other stuff
</tag>
}
static function dumpHook( $in, $argv ) {
- ob_start();
- var_dump(
- $in,
- $argv
- );
- $ret = ob_get_clean();
-
- return "<pre>\n$ret</pre>";
+ return "<pre>\n" .
+ var_export( $in, true ) . "\n" .
+ var_export( $argv, true ) . "\n" .
+ "</pre>";
}
static function staticTagHook( $in, $argv, $parser ) {