Re: Getting IP Address and previous URL from user??
| From: | Stephen Edmonds | Date: | Sun, 12 Jan 2003 16:01:56 +0000 |
| Subject: | Re: Getting IP Address and previous URL from user?? | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-17792@lists.php.net to get a copy of this message | ||
Sure. If you ever want to see what variables you can access and how they are
stored, simply write a script with
phpinfo(32);
in. It outputs ALL variables which you can access from your script. In this
case:
Remote IP (Person who accessed the script)
$_SERVER["REMOTE_ADDR"]
File that was accessed (and directory)
$PHP_SELF
Name of host (e.g. localhost from http://localhost/page.php
$_SERVER["HTTP_HOST"]
----- Original Message -----
From: "Ignacio Domínguez" <ignacioxd@idcode.sytes.net>
To: <php-windows@lists.php.net>
Sent: Sunday, January 12, 2003 3:43 PM
Subject: [PHP-WIN] Getting IP Address and previous URL from user??
> Hi. Is it possible to get the IP Address and the URL from which a request
> was made to a PHP script? I need this to implement a security barrier.
>
> I have an image that links to a PHP script. I need the IP of the client
that
> clicked on the image and the URL of the page where the image is placed.
>
> Is this possible?
>
> Thanks in advance
>
> Ignacio Domínguez
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>