=== IP Logger & Duplicate Redirector ===
Donate link: https://wolebot.com/
Contributors: oluwolefoluso
Tags: ip, logger, redirect, security, visitors
Requires at least: 6.2
Tested up to: 6.8
Requires PHP: 7.4
Stable tag: 1.2
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

A lightweight plugin to log visitor IP addresses, detect duplicates, and optionally redirect repeat visitors.

== Description ==

**IP Logger & Duplicate Redirector (ILDR)** logs the IP addresses of visitors to your WordPress site.  
You can view all logged IPs in the admin dashboard, see how many times an IP has visited, and export logs as a CSV file.  

Key features:
* Log all visitor IPs with timestamps.
* Detect duplicate IPs and optionally redirect them to a custom URL.
* Automatic IP retention cleanup after a configurable time period.
* Admin page to view logs (with pagination).
* Export logs to CSV.
* Settings page with options:
  – Set retention time (hours).
  – Enable/disable redirect.
  – Set redirect URL.
  – Exclude logged-in admins from being logged or redirected.
* Fully WordPress-native, no third-party dependencies.

== Installation ==

1. Upload the ZIP file via Plugins > Add New > Upload Plugin, or install the plugin through the WordPress Plugins screen directly.
2. Activate the plugin through the 'Plugins' screen in WordPress.
3. Go to **Settings <span aria-hidden="true" class="wp-exclude-emoji"><span aria-hidden="true" class="wp-exclude-emoji"><span aria-hidden="true" class="wp-exclude-emoji"><span aria-hidden="true" class="wp-exclude-emoji">→</span></span></span></span> IP Logger** to configure retention, redirect, and exclusions.
4. Go to **Tools <span aria-hidden="true" class="wp-exclude-emoji"><span aria-hidden="true" class="wp-exclude-emoji"><span aria-hidden="true" class="wp-exclude-emoji"><span aria-hidden="true" class="wp-exclude-emoji">→</span></span></span></span> IP Logs** to view and export visitor IP logs.

== Frequently Asked Questions ==

= Does this block visitors? =
No. It only logs and (optionally) redirects duplicate IPs. It does not block access.

= Can I exclude admins? =
Yes. Logged-in admins can be excluded from both logging and redirection.

= What happens to old IPs? =
They are automatically deleted after the retention time you set (default: 24 hours).

= Does it log backend/admin visits? =
No. The plugin only logs visits to the frontend of your site.

= Can I change the logs per page? =
Yes. In the Logs view, you can configure how many rows per page to display.

== Screenshots ==

1. Settings page with retention, redirect, and admin options.
2. Logs table showing visitor IPs, timestamps, and counts.
3. Export logs to CSV with one click.

== Changelog ==

= 1.2.0 =
* Updated to check IPs per browser session, and no longer per page Visit. This means the first browser to use an IP Address can continue visiting unlimited pages until it is closed, but the next browser with same IP address (now considered duplicate) will be redirected.

= 1.1.0 =
* Initial release with logging, redirection, settings page, log viewer, CSV export.

== Upgrade Notice ==

= 1.0.0 =
First stable release.
