json - Android: Volley request failed on my LAN -
I have a light python server that runs on my laptop at this address: 192.168.1.56. I can use it with my other computers (LAN) without any problems. I get my JSON data
In my Android app, I use the Volley Library. And I want to retrieve some JSON data on my Python server, but it does not work: I have this error:
java.lang.RuntimeException: bad url1920.168.1.56 .001001 / Todo /api/v1.0/tasks
My code:
JsonObjectRequest req = new JsonObjectRequest ("192.168.1.56 .001 / Todo / Api / v1.0 / work ", blank, new response. Lester & lt; JSONObject & gt; () {...
Thanks guys!
Ps: Without me I can ping my mobile from my laptop with such error.
I think you Your URL needs to add "http: //" to the front.
JasonObique Request REQ = New JasonObject Request ("http://192.168.1.56: 00001 / Todo / API / v1. 0 / tasks ", blank, new response. Listener & lt; JSONObject & gt; () {...
Comments
Post a Comment