0

I try to browse localhost on my samsung device. I connected my device with eclipse via wifi. browsing http://192.1.1.190 I get a "Page not avialable. I remember, some days ago it worked

but on the emulator I am able to browse localhost.

I searched on google not able to find the correct ideas.can any one know about this.

any ideas? regards

  • Possible duplicate of [How can I access my localhost from my Android device?](http://stackoverflow.com/questions/4779963/how-can-i-access-my-localhost-from-my-android-device) – JLamkin Oct 12 '16 at 15:45
  • Please see http://stackoverflow.com/questions/4779963/how-can-i-access-my-localhost-from-my-android-device for answers. – JLamkin Oct 12 '16 at 15:45
  • well USB isnt gonna create a network just connect over wifi – seven_seas Oct 12 '16 at 15:46
  • What do you have in mind when you talk about browsing a localhost? And further: Every pc or android device is its own localhost. So about which one are you talking? – greenapps Oct 12 '16 at 19:34
  • `on the emulator I am able to browse localhost.` ??? Please tell what you do and what you see. – greenapps Oct 12 '16 at 19:38

2 Answers2

0

I am currently building an Android app on the side and struggled with this problem. One solution here would be to connect your Android phone to a WiFi network which your Android Studio is also connected.

Then, when you debug your app from Android Studio, the phone should be able to access the IP address corresponding to localhost.

Tim Biegeleisen
  • 502,043
  • 27
  • 286
  • 360
0

Yes i connect android device with wifi.but my laptop wifi ip and device ip is showing different ip numbers.so i cant able to access the localhost on android device especially.

  • Please why are you posting this info as an answer. You should put info in your post. Edit your post. Or put extra info in a comment. Further: what you said makes no sense. Of course every device has a different ip address. In that way you can address each device. – greenapps Oct 12 '16 at 19:30