0
Hello, The code below only compiles if I comment on the map section, but I need it to fill in the post parameters.
Erros: method onresponse onerrorresponse does not override its superclass
There is no applicable Constructor to 'int, java.lang.String, com.mycompany.AgendaConsulado.MainActivity.(anonymous), com.mycompany.AgendaConsulado.MainActivity.(anonymous))'
url = "http://httpbin.org/post";
StringRequest postRequest = new StringRequest(Request.Method.POST, url,
new Response.Listener<String>()
{
@Override
public void onResponse(String response) {
// response
Log.d("Response", response);
}
},
new Response.ErrorListener()
{
@Override
public void onErrorResponse(VolleyError error) {
// error
//Log.d("Error.Response", response);
}
}
) {
@Override
protected Map<String, String> getParams()
{
Map<String, String> params = new HashMap<String, String>();
params.put("name", "Alif");
params.put("domain", "http://itsalif.info");
return params;
}
};
queue.add(postRequest);
Hello dvd, I understood that you formatted my question. Thank you. I have difficulty editing because put the questions by mobile.
– UltraSeven