| 开发者 | wonderfulplugins |
|---|---|
| 更新时间 | 2026年7月26日 00:00 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 7.0.1 |
| 版权: | GPLv3 |
| 版权网址: | 版权信息 |
CF-IPCountry header) into the plugin via the wonderful_geoblocking_countries_client_ip and wonderful_geoblocking_countries_pre_country_code filters.
This plugin uses IP2Location LITE data available from https://lite.ip2location.com.
wonderful-geoblocking-countries folder to the /wp-content/plugins/ directory.The IP2Location LITE database is free but published under its own license that requires every user to register for their own copy. The download with your personal token takes less than a minute and enables automatic monthly updates.
Nothing — no visitor is blocked. The plugin shows an admin notice until a database is installed, and visitors whose country cannot be determined are always let through.
Not while you are logged in: administrators are always exempt from all three rules. Only the login rule can affect you when you are logged out and your own country is on its list — the settings page warns you about exactly that.
Behind a proxy, REMOTE_ADDR is the proxy's address, not the visitor's. Use the wonderful_geoblocking_countries_client_ip filter to supply the real client IP from a header you trust, or short-circuit the lookup entirely with wonderful_geoblocking_countries_pre_country_code (e.g. return the value of Cloudflare's CF-IPCountry header).
The site access rule runs on every frontend request, including feeds and the REST API. The WordPress admin (including admin-ajax) and wp-login.php are excluded from it.
No. Country lookups run locally against the downloaded database file. The only external request is the database download itself, which you trigger with your own token.
wonderful_geoblocking_countries_country_for_ip filter so other plugins can reuse the IP2Location country lookup.