title: Amfphp Service Browser Not Displaying MySQL Result
body: <p>I am developing my first project using Amfphp and am writing my first simple Service. Here is my getData method:</p>
  
  <pre><code>    public function getData() {
      // Connect to the database using PHP Data Objects (PDO).
  
      try {
  
          $pdo = new PDO('mysql:host=localhost;port=8889;dbname=amf_test', 'root', 'root');
      } catch (PDOException $e) {
          print "Connection Error!: " . $e-&gt;getMessage() . "&lt;br/&gt;";
          die();
      }
  
      // Set an Error Handling mode.
      $pdo-&gt;setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
  
      echo "Connected successfully\n";
  
      // Retrieve all rows.
      $tsql = 'SELECT * FROM authors_aut';
      $stmt = $pdo-&gt;prepare($tsql);
      $stmt-&gt;execute();
  
      // Echo the SQL Error Code
      echo "SQL Error code: " . $pdo-&gt;errorCode() . "\n";
      $results = $stmt-&gt;fetchAll(PDO::FETCH_ASSOC);
  
      $row_count = $stmt-&gt;rowCount();
      echo $row_count.' rows selected' . "\n";
  
      foreach ($pdo-&gt;query($tsql) AS $row) {
          $id_aut = $row['id_aut'];
          $fname_aut = $row['fname_aut'];
          printf("Data: %s (%s) &lt;br /&gt;", $id_aut, $fname_aut);
      }
  
      // Close the database connection
      $stmt = null;
      $dbh = null;
  
      // Return the array.
      return $results;
  }
  </code></pre>
  
  <p>When I go to the Amfphp Back Office Service Browser, select my getData method and call it I get my comments but no data. Before I added my echo and printf lines I didn't the Service Browser returned nothing leaving me thinking my Service was not working (it still may not be!). My comments appear to show that I have successfully selected the data from the MySQL database but is it being returned?</p>
  
  <p>I welcome your thoughts.</p>
  
  <p>Chris</p>