I have a computer, and a tablet connected on a local wifi connection with a cisco router. I have a phonegap application on my computer that I load with my tablet. What I want to know is how to know the computer's ip address consistently with the tablet. I used \[code\]$ip = $_SERVER['REMOTE_ADDR'];\[/code\] however, that only works properly when I run the applcation on the computer. When I run that on my tablet I get a different ip address.Basically what I want to be able to do is to connect any computer and tablet to a router. Then my app (which is already loaded on to the tablet) will open the localhost on the computer, how do I do this. Using \[code\]$ip = $_SERVER['REMOTE_ADDR'];\[/code\] to get the computer's ip address did not work. I am open to both native android or phonegap solutions.