|
|
|
| Title : |
This is the simpliest and the most secure error-free code to get the user's
IP address and his host ( domain name ). the @ in the beginning of the
function will force PHP not to output any error messages, so it is very
useful for sendmail forms |
| Categories : |
PHP |
 Maxim Maletsky |
| Date : |
Aug 16th 2000 |
| Grade : |
5 of 5 (graded 1 times) |
| Viewed : |
5628 |
| File : |
No file for this code example. |
| Images : |
No Images for this code example. |
|
| Search : |
More code by Maxim Maletsky |
|
| Action : |
Grade This Code Example
|
|
| Tools : |
My Examples List |
|
|
|
|
|
|
if (getenv(HTTP_X_FORWARDED_FOR))
$IP=@getenv(HTTP_X_FORWARDED_FOR);
else
$IP=@getenv(REMOTE_ADDR);
$HOST=@gethostbyaddr($IP); |
|
| Query2Report : Generating Html, Pdf and Csv Reports from SQL Query Categories : PHP, PHP, HTML, PDF, Excel | | | Javascript/DHTML menus without all the extra javascipt.... server side browser detection + dynamically generated javascript (build menus on fly using php) Categories : PHP, Java Script, Navigation | | | PHP port of Matt Wrights FormMail.pl WWW form to e-mail gateway. Categories : Email, Complete Programs, Environment Variables, PHP | | | email new items in db Categories : PHP, Email, Databases, MySQL, Beginner Guides | | | pg_client_encoding -- Get the client encoding Categories : PHP, PHP Functions, PostgreSQL | | | Form is a utility class for generating html forms. It provides form initialization and regex based data validation (both server and client side) with a convenient interface. This version obsoletes version 1.0a Categories : HTML, PHP, PHP Classes, Regexps | | | DDN FFA Network Script Categories : PHP, MySQL, Complete Programs, HTML and PHP, Databases | | | A flat file counter Categories : PHP, Cookies, Filesystem, Beginner Guides | | | HTML_Graphs provides a simple PHP interface for
creating pure HTML charts. Categories : Graphics, PHP, PHP Classes, Charts and Graphs | | | Sort the results from a SELECT query (any number of columns) into an array automatically. Categories : PHP, PHP Classes, Arrays, Databases, MySQL | | | XPath for PHP without the DOM XML extension Categories : DOM XML, XML, XSLT, PHP Classes, PHP | | | Adding dashes to credit card numbers Categories : Strings, Credit Cards, PHP | | | This is a script that list all image files on a given directory, and displays
the thumbnails nicely formated within an HTML table. It also make use of
JavScript to open pop up windows when the users want to see the full photo. Categories : Graphics, PHP, Complete Programs, Java Script | | | How to display a PHP variable value from a selectbox without reloading the
page by merging PHP and Javascript variables. Categories : PHP, Java Script, Variables | | | Dynamically generated pop-ups (Select items) Categories : PHP, HTML and PHP, MySQL, Databases | |
| |
| |
|