承接 sabartampubolon/geoip 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

sabartampubolon/geoip

Composer 安装命令:

composer require sabartampubolon/geoip

包简介

Simple Geo Location Information using IP Address

README 文档

README

Latest Version on Packagist Software License Build Status Coverage Status Quality Score Total Downloads

Geo Ip took all available information from an Ip Address using data from GeoPlugin.

Work with Laravel 5.5 (tested).

Geo IP use Geoplugin to gather information.

Install

You can install GeoIp via composer.

$ composer require sabartampubolon/geoip

Requires Laravel Framework 5.5 and PHP 5.5.9 or newer. Visit GeoIp repository at Packagist.

Usage

To use GeoIp, you can simply inject GeoIp instance into Laravel controller

<?php

use Sabartampubolon\Geoip\Geoip;

// Use destination Ip
$geoip = new Geoip('8.8.8.8');
 
// Or just let it blank to automatic use client ip address
$geoip = new Geoip();
 
  
// Gather information from ip address
$info = $geoip->getInfo();

The code above will give a result in json format like this (use IP Address 8.8.8.8):

{"ip_address":"8.8.8.8","country_code":"US","country_name":"United States","city":"Mountain View","region":"CA","region_name":"California","region_code":"CA","latitude":"37.3845","longitude":"-122.0881"}

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 34
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: Pistarlabs
  • 更新时间: 2016-04-11

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固