Have app that gets input from User, and pushes to server, and PHP inserts into mySQL, but PHP isn't handleing it correctly is my assumption
<p>I got my app to accept User input and according to LogCat the app goes through my HTTP Post. But my data isn't appearing on the database. so I'm thinking its a Issue of my PHP code, but I have no idea what I did wrong with it.  I'm new to developing for android, and the research I came up with was possibly use a JSON object. I looked up a few examples of some and tried to get them to work, but kept coming up with errors. Any help would be greatly appreciated :) Here's my Code &amp; PHP hope it can help :) </p>

<pre><code>private class GrabURL extends AsyncTask&lt;String, Void, Void&gt; {
ArrayList&lt;NameValuePair&gt; nameValuePairs = new ArrayList&lt;NameValuePair&gt;();;
private ProgressDialog Dialog = new ProgressDialog(HTTPpostActivity.this);
protected void onPreExecute() {
Dialog.setMessage("Sending value..");
Dialog.show();
nameValuePairs.add(new BasicNameValuePair("fname","Donald"));
nameValuePairs.add(new BasicNameValuePair("lname", "Android"));
nameValuePairs.add(new BasicNameValuePair("phone", "502-409-5478"));
nameValuePairs.add(new BasicNameValuePair("partyNum", "10"));
nameValuePairs.add(new BasicNameValuePair("date", "2011-09-09"));
nameValuePairs.add(new BasicNameValuePair("time", "4:40"));
}

protected Void doInBackground(String... urls) {
try{
HttpClient httpclient = new DefaultHttpClient();
HttpPost httppost = new HttpPost(url);
httppost.setEntity(new UrlEncodedFormEntity(nameValuePairs));
httpclient.execute(httppost);
}catch(Exception e){
Log.e("log_tag", "Error in http connection "+e.toString());
}
return null;
}
</code></pre>

<p>PHP:</p>

<pre><code>&lt;?PHP   

$link = mysql_connect($host, $username, $password) or die("Connection ERROR");

$db = mysql_select_db("$db_name") or die ("CONNECTION ERROR");

$resTime = $_GET['time'];
$fname = $_GET['fname'];
$lname = $_GET['lname'];
$phone = $_GET['phone'];
$date = $_GET['date'];
$partyNum = $_GET['partyNum'];



$query = "INSERT INTO RESERVATION (DATE, FNAME, LNAME, NUMBERINPARTY, RESOTIME, PHONENUMBER) VALUES ('" .$date. "', '" .$fname. "', '" .$lname. "', '" .$partyNum. "', '" .$resTime. "', '" .$phone. "');"; 
?&gt;
</code></pre>
