我怎么知道IP地址和NIC卡号
我正在托管一个网站,我需要知道我网站用户的IP地址.我该如何用PHP语言做到这一点.
用户的IP地址也会动态更改,因此我们是否可以知道其NIC号或可以唯一标识它们的类似名称?
I am hosting a website and i require to know IP address of users of my website. How can i do that in PHP language.
Also IP address of users changes dynamically , so can we know their NIC No. or something similar to it which can identify them uniquely?
IP地址:
(来自 http://admincmd.blogspot.com/2007/08/php- get-client-ip-address.html [ ^ ])
IP Address:
(from http://admincmd.blogspot.com/2007/08/php-get-client-ip-address.html[^])
function getIP() {
ip ; 如果(getenv(" ) )
ip; if (getenv("HTTP_CLIENT_IP"))
ip = getenv(" ); 否则 if(getenv(" ))
ip = getenv("HTTP_CLIENT_IP"); else if(getenv("HTTP_X_FORWARDED_FOR"))