May 11, 2021
Darko G.

The URI to MaxMind GeoLite Legacy database for IPv6.


The filter hook “ip-location-block-maxmind-zip-ipv6” assigns the URI to Free GeoLite Legacy database file for IPv6 which can be downloaded by GZIP format.


  • $url
    (string) https://geolite.maxmind.com/download/geoip/database/GeoIPv6.dat.gz

Use case

The following code snippet in your theme’s functions.php can download the city database for IPv6.

function my_maxmind_ipv6( $url ) {
    return 'https://geolite.maxmind.com/download/geoip/database/GeoLiteCityv6-beta/GeoLiteCityv6.dat.gz';
add_filter( 'ip-location-block-maxmind-zip-ipv6', 'my_maxmind_ipv6' );
NOTE: When you select "mu-plugins" (ip-location-block-mu.php) as Validation timing , you should put your code snippet into drop-in.php in Geolocation API folder instead of functions.php. See My custom functions in “functions.php” doesn’t work. in FAQ for detail.



Leave a Reply

Your email address will not be published. Required fields are marked *

© 2024 - IP Location Block by IDEOLOGIX Media