How to upload file using Volley library in android?
I already have a sub class of Request<JSONObject> that is used for http post to the server. The problem is, I have no idea on how can I add a parameter for a file. Posting string to the server is easy. but I need to add file as a different parameter. How can I do it? public class AddNewPetRequest extends Request<JSONObject> { private Response.Listener<JSONObject> listener; public AddNewPetRequest(String url, Map<String, String> params, Response.Listener<JSONObject> reponseListener, Response.ErrorListener errorListener) { super(Request.Method.GET, url, errorListener); this.listener = reponseLis
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.