I want to retrieve ip4 and ip6 address of my server in a php script. Actually I use $_SERVER['SERVER_ADDR'] - this returns my ip6 address.
- Why does it return my ip6 address? My server does have two addresses: ip4 AND ip6?
- Can I force getting ip6 / ip4?