ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> php-spanish
php-spanish
[PHP-ES] Tema IP detras de proxy...
by Marco A. Mateos other posts by this author
Feb 4 2003 2:43PM messages near this date
Re: [PHP-ES] Contar usuarios actuales en la WEB | RE: [PHP-ES] Saber dias de la semana
Aqui va un ejemplo,

if (getenv(HTTP_X_FORWARDED_FOR))
{=20
 $ip=3Dgetenv(HTTP_X_FORWARDED_FOR);=20
}
else=20
if (getenv(HTTP_CLIENT_IP))
{
 $ip=3Dgetenv(HTTP_CLIENT_IP);
}
else
{=20
 $ip=3Dgetenv(REMOTE_ADDR);=20
}


Este otro,...

if(getenv(HTTP_CLIENT_IP)) {

$ip =3D getenv(HTTP_CLIENT_IP);

} elseif(getenv(HTTP_X_FORWARDED_FOR)) {

$ip =3D getenv(HTTP_X_FORWARDED_FOR);

} else {

$ip =3D getenv(REMOTE_ADDR);

Este artiuclo tambi=C3=A9n esta bien:
http://www.phpbuilder.com/columns/benedetti20021219.php3



--=20
Marco A. Mateos - Linux User: 209189
http://www.lomejordeinternet.net
http://hosting.lomejordeinternet.net
http://graficas.lomejordeinternet.net
marco@[...].net / ICQ: 172542875
Clave P=C3=BAblica disponible en pgp.rediris.es http://www.lomejordeinterne=
t.net/pgp/marco_pub_key.asc
=20
Attachments:
signature.asc

Thread:
Eduardo Daniel Pizzi
Ariel Romero
Marco A. Mateos

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved