2017 © Pedro Peláez
 

library geoservice-laravel

SypexGeo Laravel 5.5 service

image

adiesel82/geoservice-laravel

SypexGeo Laravel 5.5 service

  • Wednesday, September 6, 2017
  • by ADiesel82
  • Repository
  • 1 Watchers
  • 0 Stars
  • 68 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 5 Versions
  • 8 % Grown

The README.md

adiesel82/geoservice-laravel

GeoIP Laravel 5.5 service, (*1)

For the current moment SyperGeo service implemented only: https://sypexgeo.net, (*2)

Plaese follow next steps for install:, (*3)

1) add dependence:, (*4)

composer require adiesel82/geoservice-laravel

2) add next items into config/app.php, (*5)

'providers' => [
    ADiesel82\GeoService\GeoServiceProvider::class,
]

'aliases' => [
    'Geo' => ADiesel82\GeoService\GeoServiceFacade::class,
]

3) publish config with artisan:, (*6)

php artisan vendor:publish

Type 0 to publish all or a digit near ADiesel82\GeoService\GeoServiceProvider, (*7)

[8 ] Provider: ADiesel82\GeoService\GeoServiceProvider

It is 8 in example below and hit enter., (*8)

As result you can find geo.php in the config folder., (*9)

For the current moment SyperGeo service supported only., (*10)

Ready, (*11)

Usage example:

$result = \Geo::get(\request()->ip());
dd($result);

As result:, (*12)

{#129 ▼
  +"city": {#128 ▼
    +"id": 524901
    +"lat": 55.75222
    +"lon": 37.61556
    +"name_ru": "Москва"
    +"name_en": "Moscow"
  }
  +"country": {#130 ▼
    +"id": 185
    +"iso": "RU"
  }
}

Auto update database with composer

"post-install-cmd": [
  "ADiesel82\\GeoService\\ComposerScripts::postInstall"
],
"post-update-cmd": [
  "ADiesel82\\GeoService\\ComposerScripts::postUpdate"
],

The Versions

06/09 2017

dev-master

9999999-dev

SypexGeo Laravel 5.5 service

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

06/09 2017

0.0.5

0.0.5.0

SypexGeo Laravel 5.5 service

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

06/09 2017

0.0.4

0.0.4.0

SypexGeo Laravel 5.5 service

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

06/09 2017

0.0.3

0.0.3.0

SypexGeo Laravel 5.5 service

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

06/09 2017

0.0.2

0.0.2.0

SypexGeo Laravel 5.5 service

  Sources   Download

MIT

The Requires

  • php >=5.4.0