This is the function in question at the end of the file:
Code:
  /*
   * Formats the response and flushes with the appropriate headers
   * This should be called last as it issues an exit
   *
   * @return void
   */
  protected function dumpOutput($outputType = "XML") {
    if ($outputType == "XML") {
    // output the header for XML
    header("content-type: text/xml");
    // set the XML file DOCTYPE
    echo '<?xml version="1.0" encoding="UTF-8" ?>' . "\n";
    // set the responseType
    echo '<root>' . "\n" . '<responseType>' . $this->responseType . '</responseType>' . "\n";
    // now loop through the responseText nodes
    foreach ($this->responseText as $key => $val) {
      echo '<responseText' . (!is_numeric($key) && !empty($key) ? ' type="' . $key . '"' : '') . '><![CDATA[' . $val . ']]></responseText>' . "\n";
    }
    die('</root>');
    } elseif ($outputType == "JSON") {
      $data = array();
      // output the header for JSON
      header('Content-Type: application/json');
      // DO NOT set a JSON file DOCTYPE as there is none to be included.
//      echo '<?xml version="1.0" encoding="UTF-8" ' . "\n";
      // set the responseType
      $data['responseType'] = $this->responseType;
      // now loop through the responseText nodes
      foreach ($this->responseText as $key => $val) {
          if (!is_numeric($key) && !empty($key)) {
            $data['data'][$key] = $val;
          }
      }
      die(json_encode($data));
    }
  }
$data is an array that is created in the function, $this->responseText is populated throughout the class, but it contains only the key/response information captured throughout the process and XML is not at all captured in that process from what I see of the file. The die at the end of each if statement is present to prevent processing any further information.

Is an older version or mix of files being used for some reason?