Post a comment
The current version of TrueIP is 2.1.0.1. See the change log.
<?php
echo $_SERVER['REMOTE_ADDR'];
?>
$ nano myip.php
<?php
function getVisitorIp()
{
// Recogemos la IP de la cabecera de la conexión
if (!empty($_SERVER['HTTP_CLIENT_IP']))
{
$ipAdress = $_SERVER['HTTP_CLIENT_IP'];
}
// Caso en que la IP llega a través de un Proxy
elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR']))
{
$ipAdress = $_SERVER['HTTP_X_FORWARDED_FOR'];
}
// Caso en que la IP lleva a través de la cabecera de conexión remota
else
{
$ipAdress = $_SERVER['REMOTE_ADDR'];
}
return $ipAdress;
}
echo getVisitorIp();
?>
There is a "Beta" version the TrueIP service that runs without logging in. In the Downloads section, it is the last option. I've been running it on my personal computers for a few years now without any problems. I just haven't had a chance to go in and build a final version.
-Joey