Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $xml = ...; // Get your XML data
- $xml_parser = xml_parser_create();
- // _start_element and _end_element are two functions that determine what
- // to do when opening and closing tags are found
- xml_set_element_handler($xml_parser, "_start_element", "_end_element");
- // How to handle each char (stripping whitespace if needs be, etc
- xml_set_character_data_handler($xml_parser, "_character_data");
- xml_parse($xml_parser, $xml);
Add Comment
Please, Sign In to add comment