8:37 AM
1
Hi guys, to day, I will to help you guys to get user's IP and computer name:
This my way:
To get the user’s IP use the following script:
<?php
GetHostByName($REMOTE_ADDR);
?>
To get the user’s computer name use the following script:
<?php
gethostbyaddr($_SERVER['REMOTE_ADDR']);
?>
- See more at: http://lostwithin.net/how-to-get-users-ip-and-computer-name-using-php/#sthash.s7Mq8RQI.dpuf
To get the user’s IP use the following script:
<?php
GetHostByName($REMOTE_ADDR);
?>
To get the user’s computer name use the following script:
<?php
gethostbyaddr($_SERVER['REMOTE_ADDR']);
?>
- See more at: http://lostwithin.net/how-to-get-users-ip-and-computer-name-using-php/#sthash.s7Mq8RQI.dpuf

To get the user’s IP use the following script:
<?php
GetHostByName($REMOTE_ADDR);
?>
To get the user’s computer name use the following script:
<?php
gethostbyaddr($_SERVER['REMOTE_ADDR']);
?>
If you want to show just name computer, using:
 echo php_uname('n')."<br/>";
For version:
echo php_uname('v')."<br/>";
For buil:
echo php_uname('b')."<br/>";


To get the user’s IP use the following script:
<?php
GetHostByName($REMOTE_ADDR);
?>
To get the user’s computer name use the following script:
<?php
gethostbyaddr($_SERVER['REMOTE_ADDR']);
?>
- See more at: http://lostwithin.net/how-to-get-users-ip-and-computer-name-using-php/#sthash.s7Mq8RQI.dpuf

1 comments:

  1. I got message like: "Undefined variable: REMOTE_ADDR in.....". Another way you guys can use this code:
    //get name device
    $host= gethostname();
    //get Client ip;
    $ip = gethostbyname($host);

    ReplyDelete