koush / ion

Android Asynchronous Networking and Image Loading
Other
6.29k stars 1.03k forks source link

How to send array via setBodyParameter #941

Open mizael25 opened 4 years ago

mizael25 commented 4 years ago

int[] listid = {21, 22, 23}; Ion.with(CadastrarTime.this) .load(url2)

                    .setBodyParameter("players[]", String.valueOf(listid)) //  When I set the parameter as a array, the application crashes and I need to enter the data in the bank, my php is already working. 

                    .asJsonObject()
                    .setCallback(new FutureCallback<JsonObject>() {

}