Linux 软件免费装
Banner图

GeoIP Content Switcher

开发者 pathakhrkinc
更新时间 2026年2月13日 03:06
PHP版本: 7.4 及以上
WordPress版本: 6.9
版权: GPLv2 or later
版权网址: 版权信息

标签

woocommerce geolocation geoip country detection content switcher

下载

1.0.5

详情介绍:

GeoIP Content Switcher is a professional WordPress plugin that automatically detects your visitor's country and dynamically switches content, payments, shipping methods, and products accordingly. Perfect for international WooCommerce stores and multi-country websites. Key Features Automatic Country Detection Subdomain Redirection WooCommerce Integration Content Switching Performance Optimized Security Features Developer Friendly Shortcodes Requirements Use Cases Compatibility Themes:

安装:

Automatic Installation
  1. Log in to your WordPress admin panel
  2. Navigate to Plugins → Add New
  3. Search for "GeoIP Content Switcher"
  4. Click "Install Now" and then "Activate"
  5. Follow the setup wizard to complete configuration
Manual Installation
  1. Download the plugin ZIP file
  2. Log in to your WordPress admin panel
  3. Navigate to Plugins → Add New → Upload Plugin
  4. Choose the ZIP file and click "Install Now"
  5. Click "Activate Plugin"
Post-Installation Setup Step 1: Install MaxMind GeoLite2 Database
  1. Sign up for a free MaxMind account at https://www.maxmind.com/en/geolite2/signup
  2. Download the GeoLite2 Country database (MMDB format)
  3. Extract the GeoLite2-Country.mmdb file
  4. Upload it to: /wp-content/plugins/geoip-content-switcher/database/
Step 2: Configure Plugin Settings
  1. Go to WordPress Admin → GeoIP Switcher
  2. Select your active countries
  3. Set a default fallback country
  4. Configure subdomain mappings (if using subdomains)
  5. Set up payment and shipping rules per country
  6. Configure product visibility rules
  7. Save settings
Step 3: Test the Setup
  1. Use a VPN or proxy to test from different countries
  2. Verify subdomain redirects work correctly
  3. Check payment and shipping methods display correctly
  4. Test product visibility per country
Composer Dependencies (Advanced) If you're installing manually and the vendor folder is missing:
  1. Ensure Composer is installed on your server
  2. Navigate to the plugin directory
  3. Run: composer install --no-dev
Note: The plugin package includes all dependencies pre-installed.

屏幕截图:

  • Country configuration - Select active countries and set defaults
  • Subdomain redirect settings - Map countries to subdomains
  • Payment method filtering - Choose payment gateways per country
  • Shipping method filtering - Select shipping methods per country
  • Product visibility control - Hide categories by country
  • Homepage switcher - Assign custom homepage per country
  • Header/Footer customization - Add country-specific content

升级注意事项:

1.0.5 Initial release of GeoIP Content Switcher. Install the MaxMind GeoLite2 database after activation for full functionality.

常见问题:

Does this plugin work without WooCommerce?

Yes! The plugin works with any WordPress site. WooCommerce integration is optional and only activates if WooCommerce is installed.

Where do I get the MaxMind GeoLite2 database?

You can download it for free from MaxMind:

  1. Sign up at https://www.maxmind.com/en/geolite2/signup
  2. Download the GeoLite2 Country database (MMDB format)
  3. Place the file in the plugin's database/ folder

Is the MaxMind database included?

No, due to MaxMind's license terms, you must download it separately. It's free and takes just a few minutes to set up.

Is this plugin compatible with caching plugins?

Yes! It's fully compatible with:

  • WP Rocket
  • LiteSpeed Cache
  • W3 Total Cache
  • WP Super Cache
  • Cloudflare The plugin uses session-based caching to work seamlessly with page caching.

Does it work with Cloudflare?

Yes! The plugin automatically detects and uses Cloudflare's CF-IPCountry header for faster and more accurate country detection.

Can I use this without subdomains?

Absolutely! Subdomain redirection is optional. You can use the plugin just for content switching, payment filtering, or product visibility without any subdomain setup.

Does it support PHP 8?

Yes! Fully tested and compatible with:

  • PHP 7.4
  • PHP 8.0
  • PHP 8.1
  • PHP 8.2
  • PHP 8.3

Will this slow down my website?

No! The plugin is highly optimized:

  • Country detection is cached in sessions
  • Minimal database queries
  • Cloudflare integration for instant detection
  • Compatible with all major caching plugins

Can I customize which payment methods show per country?

Yes! The admin panel lets you select which payment gateways are available for each country.

Can I hide specific products for certain countries?

Yes! You can hide entire product categories per country through the admin settings.

Does it work with Elementor?

Yes! The plugin is fully compatible with Elementor and other page builders. You can create country-specific pages and assign them as homepages.

Is it GDPR compliant?

Yes! The plugin:

  • Only stores country code in sessions (no personal data)
  • Uses IP addresses only for geolocation (not stored)
  • Doesn't use cookies for tracking
  • Complies with GDPR requirements

Can I display the visitor's country on my site?

Yes! Use these shortcodes:

  • [geoip_country] - Shows country name
  • [geoip_country format="code"] - Shows country code
  • [geoip_ip] - Shows IP address

Does it support WooCommerce HPOS?

Yes! The plugin is fully compatible with WooCommerce High-Performance Order Storage (HPOS).

Can I test it locally?

Yes, but country detection won't work on localhost (127.0.0.1). You'll need to:

  • Use a VPN to test different countries
  • Deploy to a staging server
  • Or manually set a test country in the code

How do I update the MaxMind database?

MaxMind updates their database monthly. To update:

  1. Download the latest GeoLite2 Country database
  2. Replace the old GeoLite2-Country.mmdb file in the database/ folder
  3. Clear your site cache

Can I use this for currency switching?

Currently, the plugin focuses on content, payments, and shipping. Currency switching is planned for a future version.

Does it work with multisite?

The plugin is designed for single-site installations. Multisite compatibility is not officially supported at this time.

Where can I get support?

For support, please use the WordPress.org support forum for this plugin. For priority support or custom development, contact the developer.

更新日志:

1.0.5