[OzzModz] Country Flags by IP Address

[OzzModz] Country Flags by IP Address 2.2.1 Patch Level 3

No permission to download
I don’t think I can as that is a position for the online indicator.

What is online indicator in member popup card? Xenforo online indicator only used in Postbit. Also member popup card country flags showing in centered from web browser but only problem for mobile browser.
 
@Ozzy47 Getting Server error log:

Code:
Snog\Flags\Maxmind\Reader\InvalidDatabaseException: The MaxMind DB file contains bad data src/addons/Snog/Flags/Maxmind/Reader/Util.php:22

Generated by: Unknown account Oct 15, 2020 at 10:00 AM

Stack trace

#0 src/addons/Snog/Flags/Maxmind/Reader.php(186): Snog\Flags\Maxmind\Reader\Util::read(Resource id #5, 689751, 3)
#1 src/addons/Snog/Flags/Maxmind/Reader.php(134): Snog\Flags\Maxmind\Reader->readNode(114958, 1)
#2 src/addons/Snog/Flags/Maxmind/Reader.php(108): Snog\Flags\Maxmind\Reader->findAddressInTree('118.179.63.59')
#3 src/addons/Snog/Flags/Listener.php(100): Snog\Flags\Maxmind\Reader->get('118.179.63.59')
#4 [internal function]: Snog\Flags\Listener::Visitor(Object(Datio\AllowedEmails\XF\Entity\User))
#5 src/XF/Extension.php(67): call_user_func_array(Array, Array)
#6 src/XF/App.php(2797): XF\Extension->fire('visitor_setup', Array, NULL)
#7 src/XF/Repository/User.php(33): XF\App->fire('visitor_setup', Array)
#8 src/XF/App.php(1876): XF\Repository\User->getVisitor(7194, Array)
#9 src/XF/Pub/App.php(156): XF\App->getVisitorFromSession(Object(DBTech\Security\XF\Session\Session))
#10 src/XF/App.php(2296): XF\Pub\App->start(true)
#11 src/XF.php(465): XF\App->run()
#12 index.php(20): XF::runApp('XF\\Pub\\App')
#13 {main}

Request state

array(4) {
  ["url"] => string(130) "/forum-stats/1/results?_xfRequestUri=%2F&_xfWithData=1&_xfToken=1602733898%2C15138a35b5786f5798d24d1d8df5d0a7&_xfResponseType=json"
  ["referrer"] => string(23) "/"
  ["_GET"] => array(4) {
    ["_xfRequestUri"] => string(1) "/"
    ["_xfWithData"] => string(1) "1"
    ["_xfToken"] => string(43) "1602733898,15138a35b5786f5798d24d1d8df5d0a7"
    ["_xfResponseType"] => string(4) "json"
  }
  ["_POST"] => array(0) {
  }
}
 
That file is retrieved directly from MaXMind, the addon has no control of its contents. Try manually running the cron, Update MaxMind GeoIP database file
 
Suggestion: many users use a VPN so their country flag is incorrect. Allowing a user to choose a flag, overriding the IP selection, would be helpful.
 
Suggestion: many users use a VPN so their country flag is incorrect. Allowing a user to choose a flag, overriding the IP selection, would be helpful.
I prefer to see what IP they're using so if that were added I would hope it were optional so I could disable it.
 
Why is snog_flags.less loaded every time even if users or guests don't have permissions to view flags at all? I think it would be nice to know how we could disable this stylesheet for users without permissions to view flags, thanks!
 
Configure so users don't have permission to hide their flags.
But when setting manually for an admin from the user list, it doesn't take effect, the flag keeps showing even though I have banned it for my
 
@Ozzy47 Server error log:

Code:
Snog\Flags\Maxmind\Reader\InvalidDatabaseException: Error opening database file (data/countryflags/GeoLite2-Country.mmdb). Is this a valid MaxMind DB file? src/addons/Snog/Flags/Maxmind/Reader.php:256

Generated by: Unknown account Feb 15, 2022 at 10:01 AM

Stack trace

#0 src/addons/Snog/Flags/Maxmind/Reader.php(58): Snog\Flags\Maxmind\Reader->findMetadataStart('data/countryfla...')
#1 src/addons/Snog/Flags/Listener.php(99): Snog\Flags\Maxmind\Reader->__construct('data/countryfla...')
#2 src/XF/Extension.php(69): Snog\Flags\Listener::Visitor(Object(Datio\AllowedEmails\XF\Entity\User))
#3 src/XF/App.php(2853): XF\Extension->fire('visitor_setup', Array, NULL)
#4 src/XF/Repository/User.php(34): XF\App->fire('visitor_setup', Array)
#5 src/XF/App.php(1919): XF\Repository\User->getVisitor(3518, Array)
#6 src/XF/Pub/App.php(158): XF\App->getVisitorFromSession(Object(DBTech\Security\XF\Session\Session))
#7 src/XF/App.php(2347): XF\Pub\App->start(true)
#8 src/XF.php(517): XF\App->run()
#9 index.php(20): XF::runApp('XF\\Pub\\App')
#10 {main}
 
Enhancement request. Include country flag on 'Current Visitors' page. Mostly interested in Guest origin. Thanks for the consideration.
 
It would be great if it can show the country flag for the location when the post was posted. So they might have different flags if they travel around or use VPN.

You have another add-on OS/Browser, which does this - record and show OS/Browser info individually for every post.

ps: nothing being shown in mobile view?
 
For Registered group,

1656905101582.webp

But Registered users can still see the following option in Privacy settings:

1656905294710.webp

I have "Permit members to hide flag" checked in the add-on settings because it can be used by some groups which View country flags is set to Yes.
 
Top Bottom