[Android Q&A, Help & Troubleshooting] efowler4:
I have been trying to fix this for while now. And after reviewing several guides, tutorials, and Google searches.. I finally decided to surrender and try to make a post.

This is the PHP skeleton I am working with.

I don't think the guts of this is necessary because my problem is that this always returns the "Access Denied" in the else statement. I can't even get to the guts yet.

I guess the root of my question is, why does this 'IF' statement never evaluate to true?

if (isset($_POST['tag']) && $_POST['tag'] != '') {
//My Logic Here
}
else{
echo "Access Denied"
}

This is method in my android application that I am using to obtain the JSON data that I want my PHP code to give me.

public JSONObject addPostToFeed(String text){
List<NameValuePair> params = new ArrayList<NameValuePair>();

params.add(new BasicNameValuePair("tag", post_tag));
params.add(new BasicNameValuePair("txt", text));
JSONObject jsonFeed = jsonParser.getJSONFromUrl(feedURL, params);
Log.e("myJSON", jsonFeed.toString());
return jsonFeed;
}

And finally this is my JSONParser class.

Where the the line..

Log.e("JSON", json);

always yields, "Access Denied" when called by the method above.

package com.example.firstWebProject.library;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.UnsupportedEncodingException;
import java.util.List;

import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.NameValuePair;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.entity.UrlEncodedFormEntity;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.impl.client.DefaultHttpClient;
import org.json.JSONException;
import org.json.JSONObject;

import android.util.Log;

public class JSONParser {

static InputStream is = null;
static JSONObject jObj = null;
static String json = "";

// constructor
public JSONParser() {

}

public JSONObject getJSONFromUrl(String url, List<NameValuePair> params) {

// Making HTTP request
try {
// defaultHttpClient
DefaultHttpClient httpClient = new DefaultHttpClient();
HttpPost httpPost = new HttpPost(url);
httpPost.setEntity(new UrlEncodedFormEntity(params));

HttpResponse httpResponse = httpClient.execute(httpPost);
HttpEntity httpEntity = httpResponse.getEntity();
is = httpEntity.getContent();

} catch (UnsupportedEncodingException e) {
e.printStackTrace();
} catch (ClientProtocolException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}

try {
BufferedReader reader = new BufferedReader(new InputStreamReader(
is, "iso-8859-1"), 8);
StringBuilder sb = new StringBuilder();
String line = null;
while ((line = reader.readLine()) != null) {
sb.append(line + "\n");
}
is.close();
json = sb.toString();
Log.e("JSON", json);
} catch (Exception e) {
Log.e("Buffer Error", "Error converting result " + e.toString());
}

// try parse the string to a JSON object
try {
jObj = new JSONObject(json);
} catch (JSONException e) {
Log.e("JSON Parser", "Error parsing data " + e.toString());
}

// return JSON String
return jObj;

}
}

Please let me know I need to post anymore of my Code (i tried to keep in minimalistic)

And I am by no means an expert, so if I used any terminology wrong or any other phrasing issues with how I am presenting my problem, and advice in that area is appreciated as well.