php get ip address and host code example Example: php get ip address $clientIPAddress=$_SERVER['REMOTE_ADDR'];