Issue
I have made a php script inside localhost and I am connecting that with httpClient
but I am getting a problem.
Please tell me how can I connect to a php file at localhost from the emulator?
Solution
Thanks, @lampShaded for your answer.
In your API/URL directly use http://10.0.2.2:[your port]/
and under emulator setting add the proxy address as 10.0.2.2 with the port number. For more, you can visit: https://developer.android.com/studio/run/emulator-networking.html
Answered By - Md Imran Choudhury
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.