Go4Expert (http://www.go4expert.com/)
-   PHP (http://www.go4expert.com/forums/php/)
-   -   ipchicken clone code (http://www.go4expert.com/forums/ipchicken-clone-code-t22977/)

pein87 10Aug2010 04:27

ipchicken clone code
I used this one my personal site but since it mimics ipchicken I guess its a clone. The script makes use of the php auto global $_SERVER[]. It stores the stuff the browser sends to the server when it makes a request to a page.

PHP Code:



$port substr($_SERVER["REMOTE_PORT"],0,2);


$hostname gethostbyaddr($ip);


" " $browser;

" " $hostname;

" " $port;


You dont need to use it in the same sense as the above its just a ready made example you can copy and paste and run. If your pretty good with regex you can even broaden it to show only the browser and browser version. If you do it I'd be interested in seeing how you did it. You can optionally use:

PHP Code:

$browser get_browser(nulltrue);


but you need to edit your config file to point to the browsercap.ini file on your server.

All times are GMT +5.5. The time now is 20:43.