title: output jsonArray on php side, and decode on android
body: <p>I have this php code:</p>
  
  <pre><code>if ($merchant_rows &gt; 0){
      while($r=mysql_fetch_array($get_merchant)){
          $merchant_id = $r['merchant_id'];
      }
  
  $sql = "SELECT quest_id, quest_title, quest_price, quest_points FROM quests WHERE merchant_id = '$merchant_id'";
  $number = mysql_query($sql);
  $rows = mysql_num_rows($number);
  
  if ($rows &gt; 0){
      while($result=mysql_fetch_array($number)){
          print(json_encode($result));
      }
  }
  </code></pre>
  
  <p>and on the android side, after making an http post:</p>
  
  <pre><code>String res=response.toString();
  jObject = new JSONObject(res);
                      JSONArray sessions = jObject.getJSONArray(res);
                  for (int i = 0; i &lt; sessions.length(); i++) {   
                  JSONObject session = sessions.getJSONObject(i);  
                  Quests quest = new Quests();    
                  quest.quest_id = session.getString("quest_id");
                  quest.title = session.getString("quest_title");
                  String price = session.getString("quest_price");
                  quest.dollar_price = "$"+price;
                  String points = session.getString("quest_points");
                  quest.pts = points + "pts";
                  quests.add(quest);  }
  </code></pre>
  
  <p>My problem is that im trying to "getJSONArray" but I believe I'm not outputting the json as an array on the php side?</p>