WIP fix #71: allow parsing of large xml files
[plcapi.git] / demo / client / agesort.php
index b21bf89..60cc4b8 100644 (file)
@@ -15,7 +15,7 @@ PhpXmlRpc\Autoloader::register();
 
 $inAr = array("Dave" => 24, "Edd" => 45, "Joe" => 37, "Fred" => 27);
 print "This is the input data:<br/><pre>";
-foreach($inAr as $key => $val) {
+foreach ($inAr as $key => $val) {
     print $key . ", " . $val . "\n";
 }
 print "</pre>";
@@ -50,8 +50,8 @@ if (!$resp->faultCode()) {
     print "The server gave me these results:<pre>";
     $value = $resp->value();
     foreach ($value as $struct) {
-        $name = $struct->structmem("name");
-        $age = $struct->structmem("age");
+        $name = $struct["name"];
+        $age = $struct["age"];
         print htmlspecialchars($name->scalarval()) . ", " . htmlspecialchars($age->scalarval()) . "\n";
     }