XML2PHP() public method

XML Parser that converts an OPS protocol message into a PHP array.
public XML2PHP ( $msg ) : mixed
return mixed PHP array, or error
Beispiel #1
0
 /**
  * should convert xml to php array.
  */
 public function testXml2Php()
 {
     $ops = new Ops();
     $data = array('convert' => 'this');
     // use our built in php to xml to test
     $result = $ops->PHP2XML($data);
     // converting back, they should be the same
     $this->assertSame($data, $ops->XML2PHP($result));
 }