How To Find Out The Visitor's Ip

Table of contents:

How To Find Out The Visitor's Ip
How To Find Out The Visitor's Ip

Video: How To Find Out The Visitor's Ip

Video: How To Find Out The Visitor's Ip
Video: How To Know The People Visiting Your Site, Country, IP Address And Browser 2024, May
Anonim

How to find out who visited your site, from which ip-addresses they came to it? Or who is on it at the moment? This and other information can be obtained by inserting the simplest scripts on the page of your Internet resource.

How to find out the visitor's ip
How to find out the visitor's ip

Instructions

Step 1

You can find out who has visited your site using a free attendance counter: https://gostats.ru/ Study the information provided there, insert the counter code into your site. In his reports, you will find all the information you need about visitors to your resource. The service https://iplogger.ru/ has similar characteristics.

Step 2

There are a lot of similar resources on the network, but they have one drawback - there is no certainty that the link added to the site (as in the case of the last specified service) does not lead to a sniffer stealing confidential information.

Step 3

If you do not trust third-party services too much, you can organize the accounting of IP-addresses of visitors directly on your website. To find out who visited it, you need to insert the following code on the page, after the closing tag / html:

Step 5

This code is written in PHP and gives information about the time of entering the site, the visitor's ip-address and the browser used. All information is written to the base.php text file. To create it, simply open a blank text file (in Notepad) and save it as base.txt, then rename the extension to php and put the file in the root directory. To see who visited your site, just type in the browser: _https:// your_site_address/base.php

Step 6

So that no one else can read the file with the reports, enter the line in it: But in this case, you yourself can view the log only through the site's control panel.

Recommended: