日期:2014-05-20  浏览次数:20723 次

HttpClient 里面 httpPost、setEntity提交的,在后台通过什么方式接收值
HttpPost httpPost=new HttpPost(posturl);
//建立一个NameValuePair数组,用于存储欲传递的参数
List params=new ArrayList();
//添加参数
params.add(new BasicNameValuePair("start", "0"));
params.add(new BasicNameValuePair("size", "14"));
params.add(new BasicNameValuePair("sortType", "hot"));

try {
//设置编码
httpPost.setEntity(new UrlEncodedFormEntity(params,HTTP.UTF_8));
//发送Post,并返回一个HttpResponse对象  
HttpResponse response = client.execute(httpPost);


中间的这个params的值在服务器有什么方式来接收啊
httpPost.setEntity(new UrlEncodedFormEntity(params,HTTP.UTF_8));


大神指点、在线等....
HttpClient? httpPost setEntity 参数 接收

------解决方案--------------------
request.getparameter?
------解决方案--------------------
引用:
request.getparameter?


+1024

管你什么东西提交的请求,在服务器端都servlet容器封装成httprequest