GeoIP2-php | PHP API for GeoIP2 webservice client and database reader | REST library

 by   maxmind PHP Version: v2.13.0 License: Apache-2.0

kandi X-RAY | GeoIP2-php Summary

kandi X-RAY | GeoIP2-php Summary

GeoIP2-php is a PHP library typically used in Web Services, REST applications. GeoIP2-php has no bugs, it has no vulnerabilities, it has a Permissive License and it has medium support. You can download it from GitHub.

This package provides an API for the GeoIP2 and GeoLite2 web services and databases.

            kandi-support Support

              GeoIP2-php has a medium active ecosystem.
              It has 2183 star(s) with 269 fork(s). There are 100 watchers for this library.
              It had no major release in the last 12 months.
              There are 1 open issues and 98 have been closed. On average issues are closed in 32 days. There are 1 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of GeoIP2-php is v2.13.0

            kandi-Quality Quality

              GeoIP2-php has 0 bugs and 0 code smells.

            kandi-Security Security

              GeoIP2-php has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              GeoIP2-php code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              GeoIP2-php is licensed under the Apache-2.0 License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              GeoIP2-php releases are available to install and integrate.
              Installation instructions, examples and code snippets are available.
              GeoIP2-php saves you 308 person hours of effort in developing the same functionality from scratch.
              It has 752 lines of code, 53 functions and 32 files.
              It has low code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi has reviewed GeoIP2-php and discovered the below as its top functions. This is intended to give you an instant insight into GeoIP2-php implemented functionality, and help decide if they suit your requirements.
            • Get response for geoip2 .
            • Get a record from the database .
            • Generate CIDR from IP address .
            • Create the subdivision records .
            • Create a model for a given class .
            • Get first set name locale .
            • Get field value
            • Returns the locale name .
            • Get the most specific subdivision .
            • Check if attribute is valid .
            Get all kandi verified functions for this library.

            GeoIP2-php Key Features

            No Key Features are available at this moment for GeoIP2-php.

            GeoIP2-php Examples and Code Snippets

            No Code Snippets are available at this moment for GeoIP2-php.

            Community Discussions

            Trending Discussions on GeoIP2-php


            Maxmind's GeoLite2 Continent code
            Asked 2018-Jun-17 at 22:02

            I'm using MaxMind's free GeoLite2 database.
            According to their code, I can get the country's ISO code.
            print($record->country->isoCode . "\n"); // 'US'
            But how do I get the continent code ? I'm more specifically looking for EU detection.



            Answered 2018-Jun-17 at 22:02


            The list of EU (European Union) countries is:

            • AT, Austria
            • BE, Belgium
            • BG, Bulgaria
            • CR, Croatia
            • CY, Republic of Cyprus
            • CZ, Czech Republic
            • DK, Denmark
            • EE, Estonia
            • FI, Finland
            • FR, France
            • DE, Germany
            • GR, Greece
            • HU, Hungary
            • IE, Ireland
            • IT, Italy
            • LV, Latvia
            • LI, Lithuania
            • LU, Luxembourg
            • MT, Malta
            • NL, Netherlands
            • PL, Poland
            • PT, Portugal
            • RO, Romania
            • SK, Slovakia
            • SI, Slovenia
            • SP, Spain
            • SE, Sweden
            • GB, United Kingdom

            example of what I use:


            Community Discussions, Code Snippets contain sources that include Stack Exchange Network


            No vulnerabilities reported

            Install GeoIP2-php

            We recommend installing this package with Composer.
            To download Composer, run in the root directory of your project:. You should now have the file composer.phar in your project directory.
            Run in your project root:. You should now have the files composer.json and composer.lock as well as the directory vendor in your project directory. If you use a version control system, composer.json should be added to it.
            Although we strongly recommend using Composer, we also provide a phar archive containing most of the dependencies for GeoIP2. Our latest phar archive is available on our releases page.
            In order to use the phar archive, you must have the PHP Phar extension installed and enabled. If you will be making web service requests, you must have the PHP cURL extension installed to use this archive. For Debian based distributions, this can typically be found in the the php-curl package. For other operating systems, please consult the relevant documentation. After installing the extension you may need to restart your web server.


            Please report all issues with this code using the GitHub issue tracker. If you are having an issue with a MaxMind service that is not specific to the client API, please see our support page.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
          • HTTPS


          • CLI

            gh repo clone maxmind/GeoIP2-php

          • sshUrl


          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link