Skip to content

Hornet-Wing/laravel-geoip2

 
 

Repository files navigation

GeoIP2 for Laravel 7.x, 8.x, 9.x, 10.x and 11.x

Note: For Laravel 5.2-5.3 use version tagged 1.1.5
Note: For Laravel 5.4-5.8 use version tagged 2.0.2
Note: For Laravel 6.x use version tagged 3.0.2

Installation

  1. As it is currently not published to packagist, you first need to reference this repo in the composer.json like so:
"repositories": [
	{
		"type": "git",
		"url": "https://github.com/Hornet-Wing/laravel-geoip2"
	}
]
  1. In order to install run the following composer command:
composer require talkative/laravel-geoip2
  1. Run the command below to publish the package:
$ php artisan vendor:publish --provider="Talkative\LaravelGeoIP2\GeoIP2ServiceProvider"
  1. Run the update command to download the latest required databases
$ php artisan geoip:update