我想从移动版网站检索 html 源代码,
String url = "m.kitco.com";
HttpClient client = new DefaultHttpClient();
HttpGet request = new HttpGet(url);
HttpResponse response = client.execute(request);
InputStream in = response.getEntity().getContent();
BufferedReader reader = new BufferedReader(new InputStreamReader(in));
但是,我能得到的源代码只是完整的站点源代码,而不是移动版本。似乎网络服务器会自动将链接转发到完整站点。
如何强制它检索移动网站 html 源代码?