| | |||||
| ||||||||
| Webmaster Tutorials Instructional webmaster-related how-to's and tutorials. |
![]() |
| | LinkBack | Thread Tools |
| | THREAD STARTER #1 (permalink) |
| NamePros Regular Join Date: Sep 2005 Location: At Home
Posts: 881
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | Getting current user's IP address While looking in the PHP predefined variables i found an intersting one: $_ENV["REMOTE_ADDR"]. what this does is it gives the current IP of the person viewing your site. This is quite good if you are making a poll for a intranet where each user has their own username. ????: NamePros.com http://www.namepros.com/webmaster-tutorials/173494-getting-current-users-ip-address.html Have a look at this and tell me what you think. PHP Code: ASGSOFT
__________________ |
| |
| | #6 (permalink) |
| NamePros Regular Join Date: Oct 2005
Posts: 205
![]() ![]() | Slightly different method, same info: ????: NamePros.com http://www.namepros.com/showthread.php?t=173494 Code: <?php
echo "<html><head><title>lifted from www.scanmybrowser.com</title></head>";
echo "<body><h1>A few request header variables:</h1>";
echo "HTTP_REFERER=".getenv("HTTP_REFERER")."<br>";
echo "REMOTE_ADDR=".getenv("REMOTE_ADDR")."<br>";
echo "HTTP_USER_AGENT=".getenv("HTTP_USER_AGENT")."<br>";
echo "HTTP_ACCEPT=".getenv("HTTP_ACCEPT")."<br>";
echo "HTTP_ACCEPT_LANGUAGE=".getenv("HTTP_ACCEPT_LANGUAGE")."<br>";
echo "HTTP_ACCEPT_CHARSET=".getenv("HTTP_ACCEPT_CHARSET")."<br>";
echo "HTTP_ACCEPT_ENCODING=".getenv("HTTP_ACCEPT_ENCODING")."<br>";
echo "</body></html>";
?> |
| |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| 77% of Google users.... | holeinone | Industry News | 22 | 03-07-2006 07:30 AM |
| Users Online Counter Hosting Script | BoxFresh | Scripts For Sale | 3 | 08-29-2005 10:41 AM |
| Php code for getting IP Address of users. | bbalegere | CODE | 2 | 08-22-2005 04:51 AM |
| Users Online Hosting - PHP Script *Cheap* | Elemental | Scripts For Sale | 1 | 02-04-2005 12:21 PM |