diff options
Diffstat (limited to 'ext/xml/tests/xml_set_processing_instruction_handler_basic.phpt')
-rw-r--r-- | ext/xml/tests/xml_set_processing_instruction_handler_basic.phpt | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/ext/xml/tests/xml_set_processing_instruction_handler_basic.phpt b/ext/xml/tests/xml_set_processing_instruction_handler_basic.phpt index e5589cee29..d38085d26c 100644 --- a/ext/xml/tests/xml_set_processing_instruction_handler_basic.phpt +++ b/ext/xml/tests/xml_set_processing_instruction_handler_basic.phpt @@ -1,28 +1,28 @@ --TEST-- -Test xml_set_processing_instruction_handler function : basic +Test xml_set_processing_instruction_handler function : basic --SKIPIF-- -<?php +<?php if (!extension_loaded("xml")) { - print "skip - XML extension not loaded"; -} + print "skip - XML extension not loaded"; +} ?> --FILE-- <?php /* Prototype : proto bool xml_set_processing_instruction_handler ( resource $parser , callback $handler ) * Description: Sets the processing instruction (PI) handler function for the XML parser. * Source code: ext/xml/xml.c - * Alias to functions: + * Alias to functions: */ class XML_Parser { - + function PIHandler($parser, $target, $data) { echo "Target: " . $target. "\n"; echo "Data: " . $data . "\n"; } - + function parse($data) { $parser = xml_parser_create(); @@ -32,7 +32,7 @@ class XML_Parser xml_parser_free($parser); } - + } $xml = <<<HERE @@ -40,10 +40,10 @@ $xml = <<<HERE <?xml-stylesheet href="default.xsl" type="text/xml"?> HERE; -echo "Simple test of xml_set_processing_instruction_handler() function\n"; +echo "Simple test of xml_set_processing_instruction_handler() function\n"; $p1 = new Xml_Parser(); -$p1->parse($xml); -echo "Done\n"; +$p1->parse($xml); +echo "Done\n"; ?> --EXPECT-- Simple test of xml_set_processing_instruction_handler() function |