我在理解下面的代码行时遇到了一些问题。究竟是什么做的,它是如何帮助我查询在AndroidAndroid查询外部MySQL数据库
$q=mysql_query("SELECT * FROM people WHERE birthyear>'".$_REQUEST['year']."'");
while($e=mysql_fetch_assoc($q))
$output[]=$e;
print(json_encode($output));
我知道初始部分的数据库就意味着选择表的人那里birthyear每个记录......
不过,我以后困惑了。我从Android使用http调用这个php函数post
ArrayList nameValuePairs = new ArrayList();
nameValuePairs.add(new BasicNameValuePair("year","1980"));
HttpClient httpclient = new DefaultHttpClient();
HttpPost httppost = new HttpPost("http://10.0.2.2/retrieve.php");
httppost.setEntity(new UrlEncodedFormEntity(nameValuePairs));
HttpResponse response = httpclient.execute(httppost);
HttpEntity entity = response.getEntity();
is = entity.getContent();
输入流在哪里。有人可以帮我吗?