Advertisement
Guest User

Untitled

a guest
May 7th, 2016
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.17 KB | None | 0 0
  1. <?php
  2. /**
  3. *
  4. * @ This file is created by deZender.Net
  5. * @ deZender (PHP5 Decoder for Zend Encoder/SafeGuard & PhpExpress)
  6. *
  7. * @ Version : 1.1.6.0
  8. * @ Author : DeZender
  9. * @ Release on : 02.06.2013
  10. * @ Official site : http://DeZender.Net
  11. *
  12. */
  13.  
  14. class XMLToArray {
  15. public $parser = null;
  16. public $node_stack = array( );
  17.  
  18. /** PUBLIC
  19. * If a string is passed in, parse it right away.
  20. */
  21. public function XMLToArray($cdiegbjedd = '') {
  22. if ($cdiegbjedd) {
  23. return $this->parse( $cdiegbjedd );
  24. }
  25.  
  26. return true;
  27. }
  28.  
  29. /** PUBLIC
  30. * Parse a text string containing valid XML into a multidimensional array
  31. * located at rootnode.
  32. */
  33. public function parse($cdiegbjedd = '') {
  34. $this->parser = xml_parser_create( );
  35. xml_set_object( $this->parser, $this );
  36. xml_parser_set_option( $this->parser, XML_OPTION_CASE_FOLDING, false );
  37. xml_set_element_handler( $this->parser, 'startElement', 'endElement' );
  38. xml_set_character_data_handler( $this->parser, 'characterData' );
  39. $this->node_stack = array( );
  40. ........................................................................
  41. .......................................
  42. ..............
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement