make a search request from android to mysql/php
<p>I'm trying to make a search request from android to mysql/php via a json web service,so this my code for android side:</p>

<pre><code>public class Recherche_produit extends Activity {


    public String strURL="http://192.168.1.100/res_research2.php";

    public String terme_search;
    EditText to_search;
    Button go_search;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        // TODO Auto-generated method stub
        super.onCreate(savedInstanceState);

        setContentView(R.layout.recherche_produit);

    to_search=(EditText)findViewById(R.id.edittext_recherche);

    go_search=(Button)findViewById(R.id.go_research);
    go_search.setOnClickListener(new OnClickListener() {

        @Override
        public void onClick(View v) {
            // TODO Auto-generated method stub

            envoyer_recherche();


        }


    });



    }

    private void envoyer_recherche() {
        // TODO Auto-generated method stub

        terme_search=to_search.getText().toString();
        Toast.makeText(getApplicationContext(), terme_search, Toast.LENGTH_LONG).show();


        ArrayList&lt;NameValuePair&gt; nameValuePairs = new ArrayList&lt;NameValuePair&gt;();
        nameValuePairs.add(new BasicNameValuePair("CONTENU",terme_search));




        try{
            HttpClient httpclient = new DefaultHttpClient();
            HttpPost httppost = new HttpPost(strURL);
            httppost.setEntity(new UrlEncodedFormEntity(nameValuePairs));

            httpclient.execute(httppost);


        }catch(Exception e){
            Log.e("log_tag", "Error in http connection " + e.toString());
        }



    }


}
</code></pre>

<p>and here the server side code:</p>

<pre><code>&lt;?php
  require_once 'configuration_parametres.php';
  $terme_recherche=$_POST['CONTENU'];
  echo $terme_recherche;
  $sql=mysql_query("SELECT * FROM livres WHERE titre_liv='$terme_recherche'");
  while($row=mysql_fetch_assoc($sql))
  $output[]=$row;
  print(json_encode($output));
  mysql_close();

  ?&gt;
</code></pre>

<p>and here's my logcat:
thx,this my logcat:
`</p>

<pre><code>02-20 19:04:41.529: I/ActivityManager(70): Starting: Intent { cmp=fsg.mpssri.MEGAMAG/.Recherche_produit } from pid 382
02-20 19:04:42.019: I/ActivityManager(70): Displayed fsg.mpssri.MEGAMAG/.Recherche_produit: +473ms
02-20 19:04:53.139: D/dalvikvm(382): GC_CONCURRENT freed 816K, 50% free 3419K/6727K, external 7084K/8475K, paused 9ms+5ms
02-20 19:05:50.519: D/SntpClient(70): request time failed: java.net.SocketException: Address family not supported by protocol
02-20 19:06:39.689: I/EventLogService(178): Aggregate from 1361385399046 (log), 1361385399046 (data)
02-20 19:06:44.779: D/dalvikvm(178): GC_EXPLICIT freed 158K, 48% free 3247K/6215K, external 1625K/2137K, paused 85ms
02-20 19:07:00.359: I/dalvikvm(382): Jit: resizing JitTable from 512 to 1024
02-20 19:07:54.850: D/dalvikvm(382): GREF has increased to 201
</code></pre>

<p>it show nothing when i run the php file in the browser !!!
please help me </p>
