countries-states-cities-database | 🌍 Discover our global repository | JSON Processing library

 by   dr5hn PHP Version: v1.9 License: ODbL-1.0

kandi X-RAY | countries-states-cities-database Summary

kandi X-RAY | countries-states-cities-database Summary

countries-states-cities-database is a PHP library typically used in Utilities, JSON Processing applications. countries-states-cities-database has no bugs, it has no vulnerabilities, it has a Strong Copyleft License and it has medium support. You can download it from GitHub.

Full Database of city state country available in JSON, SQL, XML, YAML & CSV format. All Countries, States & Cities are Covered & Populated with Different Combinations & Versions.

            kandi-support Support

              countries-states-cities-database has a medium active ecosystem.
              It has 5022 star(s) with 2063 fork(s). There are 111 watchers for this library.
              It had no major release in the last 12 months.
              There are 44 open issues and 283 have been closed. On average issues are closed in 123 days. There are 1 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of countries-states-cities-database is v1.9

            kandi-Quality Quality

              countries-states-cities-database has no bugs reported.

            kandi-Security Security

              countries-states-cities-database has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              countries-states-cities-database is licensed under the ODbL-1.0 License. This license is Strong Copyleft.
              Strong Copyleft licenses enforce sharing, and you can use them when creating open source projects.

            kandi-Reuse Reuse

              countries-states-cities-database releases are available to install and integrate.
              Installation instructions are not available. Examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of countries-states-cities-database
            Get all kandi verified functions for this library.

            countries-states-cities-database Key Features

            No Key Features are available at this moment for countries-states-cities-database.

            countries-states-cities-database Examples and Code Snippets

            No Code Snippets are available at this moment for countries-states-cities-database.

            Community Discussions


            Extract Json data from a countries.csv file on github, and create a seperate array of timezones
            Asked 2022-Apr-01 at 09:27


            this is countries.csv file, and i want to extract all the timezones from it, which is its 14th colomn, and the data in there is not properly json formatted. I'm trying to parse the json but it failed. Actually, I want to create an array of timezones like this



            Answered 2022-Apr-01 at 09:15

            Following code would do, what you aim.

            Please do not forget to mark this answer as ACCEPTED and thumbs up if it solves your problem, so that the work of the developers who help is appreciated and other developers can see in question list, that your question has already an accepted answer.



            Laravel 8: ErrorException::("PDO::exec(): MySQL server has gone away") when calling DB::unprepared($sql)
            Asked 2021-Dec-06 at 10:35

            I run a laravel seeder:



            Answered 2021-Dec-06 at 10:35

            I solve it by setting max_allowed_packet=200MB under [mysqld] in my.ini then restart your mysql .

            I was set max_allowed_packet under [mysqldump] which is wrong.

            MySQL dump: is only for exporting sql. MySQL: is MySQL client (or mysql deamon program) which used to running queries (in my case inserting this big 16 MB sql file)

            Reference this serverfault question: difference between mysql and mysqldump



            Laravel Eloquent A good way to make relationship between country state and city table
            Asked 2021-May-04 at 11:10

            I have 3 tables with schema like below



            Answered 2021-May-04 at 11:10

            Just Change The Primary Keys of each table to code,state_code,city_code Respectively

            NB:change multiple to unique the state_code in states table and city_code in cities table

            And In your Models change The Relationship like

            /* return $this->hasMany(Model::class, 'foreign_key', 'local_key');*


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


            No vulnerabilities reported

            Install countries-states-cities-database

            You can download it from GitHub.
            PHP requires the Visual C runtime (CRT). The Microsoft Visual C++ Redistributable for Visual Studio 2019 is suitable for all these PHP versions, see You MUST download the x86 CRT for PHP x86 builds and the x64 CRT for PHP x64 builds. The CRT installer supports the /quiet and /norestart command-line switches, so you can also script it.


            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            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 dr5hn/countries-states-cities-database

          • 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

            Explore Related Topics

            Reuse Pre-built Kits with countries-states-cities-database

            Consider Popular JSON Processing Libraries


            by nlohmann


            by alibaba


            by stedolan


            by google


            by paularmstrong

            Try Top Libraries by dr5hn


            by dr5hnJavaScript


            by dr5hnJavaScript


            by dr5hnJavaScript


            by dr5hnShell


            by dr5hnPHP