• Resolved theboina

    (@theboina)


    It would be great if we could copy and paste the countries that are blocked, so we could apply them directly without having to import and export them.
    As the field is a drop-down list, you can’t select items with the mouse to copy and paste them, which is a problem when you have several sites to manage and want to quickly update the list without having to select items from the drop-down menu.

    Thanks for the plugin!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author IniLerm

    (@inilerm)

    Hi @theboina,

    Thank you for the excellent feedback! You are completely right; the visual dropdown (Select2) is great for selecting a few countries on a single site, but it becomes a bottleneck when you manage a fleet of websites and want to replicate a 50-country blocklist quickly.

    I have added a feature request to our roadmap to implement a “Raw Text” mode or a “Paste to Select” function for the country fields in an upcoming update to solve exactly this.

    In the meantime, here is a Pro-Tip workaround (For Advanced Users):

    Since the full Import/Export feature overwrites all settings, you can do a surgical “copy-paste” using the JSON files if you are comfortable with text editors:

    1. On the source site, go to Security > Settings > Import / Export and click “Export Template (No API Keys)”.
    2. Open the downloaded .json file in a code editor (like VS Code or Notepad++).
    3. Search for the line “geoblock_countries”: [.
    4. Copy that entire array block (down to the closing ],). Example:codeJSON
    5. "geoblock_countries": [ "AF", "BD", "CN" ],
    6. On your destination site, do an Export of the current settings.
    7. Open that file, find the empty “geoblock_countries”: [], array, and replace it with the block you copied.
    8. Save the file and Import it back into the destination site.

    ⚠️ CRITICAL WARNING: JSON formatting is extremely strict. If you miss a comma or a bracket when pasting, the import will fail or corrupt your settings. Please always keep an unmodified backup of your JSON before experimenting!

    Thanks again for helping us identify these workflow bottlenecks.

    Best regards,

    Advanced IP Blocker Team

    Plugin Author IniLerm

    (@inilerm)

    Hi @theboina,

    Following up on my previous message regarding the JSON workaround, I want to add a very important word of caution.

    While editing the JSON file is currently the only way to “copy-paste” the country list between sites, it is a highly advanced method that carries significant risk.

    Please be aware of the following before trying it:

    1. Total Overwrite: When you import a JSON file into a new site, it completely overwrites ALL existing Advanced IP Blocker settings on that site. It does not just update the country list; it replaces your entire configuration (WAF rules, logging preferences, etc.).
    2. The Safe Workflow: If you must use this method, you should always:
      • First, Export the current settings from the Destination Site (to get its exact, current configuration).
      • Open that specific file in a code editor.
      • Carefully paste the “geoblock_countries”: […] array from your Source Site into it, making sure not to break the JSON formatting (watch out for missing or extra commas!).
      • Save and Import it back into the Destination Site.
    3. The Risk: If the JSON formatting is broken even slightly, the import will fail, and the plugin’s configuration could become corrupted or revert to defaults, leaving the site unprotected.

    Because of these risks, we generally do not recommend manually editing the JSON files unless you are very comfortable with code editors and always keep a safe backup of the original export.

    We are actively working on adding a safe, built-in “Bulk Paste” feature for the country selector in a future update to solve this problem properly and safely.

    Thank you for your understanding!

    Best regards,

    Advanced IP Blocker Team

    Plugin Author IniLerm

    (@inilerm)

    Hi @theboina,

    Great news! Following up on our previous conversation, you can officially forget about the risky JSON workaround.

    Thanks to your excellent feedback, we have just implemented a safe, built-in “Copy/Paste Raw Codes” feature. We will be releasing version 8.9.2 in the next few hours, which includes this highly requested improvement.

    Here is how the new feature works:

    1. Under any country selector (Geoblocking, Geo-Challenge, or Whitelist Login), you will now see a new “Copy/Paste Raw Codes” button.
    2. Clicking it opens a text area containing your currently selected countries as 2-letter codes (e.g., US, CA, MX).
    3. You can easily copy this list and paste it into other sites you manage.
    4. The system is smart enough to extract only the valid 2-letter codes from whatever you paste and safely ignore any other text or invalid formatting, preventing any risk of corruption to your settings.

    A quick but very important recommendation when configuring your countries:

    • Geoblocking vs. Geo-Challenge: Please make sure you do not add the same countries to both the Geoblocking list and the Geo-Challenge list simultaneously. If a country is already blocked via Geoblocking, sending them a Geo-Challenge has no effect (they are simply blocked). Choose one method per country.
    • Whitelist Login Countries: Ensure that the countries you place in the “Whitelist Login Countries” list are never included in your Geoblocking or Geo-Challenge lists. Otherwise, you risk contradicting the rules and accidentally blocking legitimate login attempts.

    Thank you once again for helping us improve Advanced IP Blocker. Keep an eye out for the 8.9.2 update in your dashboard shortly!

    Best regards,

    Advanced IP Blocker Team

    Plugin Author IniLerm

    (@inilerm)

    = 8.9.2 = is now available !!

    • NEW FEATURE: Select2 Country Copy/Paste. You no longer have to manually select 50+ countries repeatedly on multi-site environments. A new hidden tool now lets you copy completely raw 2-letter codes from any source and paste them straight into Geoblocking, GeoChallenge, and Whitelist Login Country elements.
    • UX: Added a clear warning to users that having intersecting rules between Geoblocking and Whitelist Login Countries leads to undefined behavior.
    • This function requires that the sites be updated to 8.9.2 or higher
    • This reply was modified 2 months, 3 weeks ago by IniLerm.
    Thread Starter theboina

    (@theboina)

    Great news! Thank you for rolling out this feature so quickly.
    The JSON format is useful, but adding and removing countries is more tedious; this copy-and-paste method is much more intuitive and reduces the chance of errors.
    Congratulations on the plugin!

Viewing 5 replies - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.