Info from the URL
<p>I want to create an Application, the description of it as follows</p>

<ul>
<li>Perform search </li>
<li>Display the results.</li>
</ul>

<p>Basically, I want to create an application for an existing web-site which does this, but my need is to create for a Mobile.</p>

<p>Based on the website link, it refers to some ASP pages. for e.g. <a href="http://test.com/query.asp" rel="nofollow">http://test.com/query.asp</a>. The website allows the user to enter various input for search. </p>

<p>I want to create and then send the same request to the server and get the result. How can I know what all parameters/headers it is taking and what format is the response (XML or JSON).</p>

<p>Below is my sample code for the Android Device</p>

<pre><code>            HttpClient httpclient = new DefaultHttpClient();
        HttpPost httpPost = new HttpPost(url);
        List nameValuePairs = new ArrayList(3);
        //this is where you add your data to the post method
        nameValuePairs.add(new BasicNameValuePair("sel", "1"));
        nameValuePairs.add(new BasicNameValuePair("txt", "2466"));
        nameValuePairs.add(new BasicNameValuePair("selr", "2011"));
        httpPost.setEntity(new UrlEncodedFormEntity(nameValuePairs));
        // Execute HTTP Post Request
        HttpResponse response = httpclient.execute(httpPost);
        content = response.getEntity().getContent();
        return content;
</code></pre>

<p>// Update
Ok, now I am able to get the desired output from the web query.
I printed the result for my Http Post request and I saw some HTML tags in it. In short, it prints the source of the HTML page that has to be displayed. </p>

<p>Is there a way to display the HTML view in my Android Application? Or a way to fetch only the relavant data from the response and ignore the HTML tags etc..?</p>

<p>First line of the response looks like </p>

<pre><code>06-17 16:35:21.756: DEBUG/(30307): &lt;script language="javascript" type=text/css&gt;
</code></pre>

<p>//</p>

<p>Regards,
Nirav</p>
