breautek edited a comment on issue #267:
URL: https://github.com/apache/cordova/issues/267#issuecomment-766349767


   If you're testing on a physical device, then `localhost` is not going to 
work, as that refers to the local device  (aka the phone itself), which I 
assume the server isn't running on.
   
   You need to make sure the following:
   - the server is bound to a reachable ip address. For simplicity, the server 
can listen on 0.0.0.0, which means use any available ip address.
   - the server and the device should be connected to the same network. If 
you're on a home network, then your ip address will probably look like 
192.168.x.y. `x` will be the same for your phone and the server, but `y` will 
be different.
   - finally, in your app, you should be referencing the server ip address, not 
localhost or 127.0.0.1.
   
   To determine the ip address on the server use `ipconfig` on windows, or 
`ifconfig` on linux/mac.
   
   Let me know if this helps.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cordova.apache.org
For additional commands, e-mail: commits-h...@cordova.apache.org

Reply via email to