I am building an android app that needs to download and synchronise with an online database, I am sending my query from the app to a php page which returns the relevant rows
On Arrays, look for:
JSONArray menuitemArray = popupObject.getJSONArray("menuitem");