hi i am using the following code to get the local machine ip from java applet but i always getting 127.0.0.1 instead of actual ip
public String ip;
public void init()
{
    try
    {
        Enumeration<NetworkInterface> n = NetworkInterface.getNetworkInterfaces();
        for (; n.hasMoreElements();)
        {
            NetworkInterface e = n.nextElement();
            Enumeration<InetAddress> a = e.getInetAddresses();
            for (; a.hasMoreElements();)
            {
                InetAddress addr = a.nextElement();
                ip = "Really " + addr.getHostAddress();
                System.out.println(ip);
            }
        } 
    }
    catch(Exception ex)
    {
    }       
}
 
     
     
     
     
     
    