Noid Posted May 29, 2011 Share Posted May 29, 2011 Hey guys, is there any way to get the IP address of people accessing my website using PHP? I'm trying to get a statistics area to work for my website. If there isn't a way using PHP, what would be an application which can get the IP address? Thanks a lot, Noid Link to comment https://forums.phpfreaks.com/topic/237790-getting-the-ip-address/ Share on other sites More sharing options...
mikesta707 Posted May 29, 2011 Share Posted May 29, 2011 use the REMOVE_ADDR index of the $_SERVER super global array. For example $ip=$_SERVER['REMOTE_ADDR']; Link to comment https://forums.phpfreaks.com/topic/237790-getting-the-ip-address/#findComment-1221930 Share on other sites More sharing options...
Noid Posted May 29, 2011 Author Share Posted May 29, 2011 Thanks a bunch . Link to comment https://forums.phpfreaks.com/topic/237790-getting-the-ip-address/#findComment-1221932 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.