Answer the question
In order to leave comments, you need to log in
SyncHttpClient not working?
Help plz. SyncHttpClient calls onFailure(). there is emptiness in it. those. response = null, header = null, status = 0. I just can't figure out what I don't like.
I use the loopj SyncHttpClient library (not AsyncHttpClient. I need a synchronous request)
import com.loopj.android.http.SyncHttpClient;
SyncHttpClient client = new SyncHttpClient();
RequestParams params = new RequestParams();
params.put("par", value);
client.post(request_uri, params, new JsonHttpResponseHandler() {
@Override
public void onSuccess(int i, Header[] headers, org.json.JSONObject response) {
}
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question