PHP Classes

File: application/config/geolocation.php

Recommend this page to a friend!
  Classes of Simo  >  CodeIgniter Geolocation Library  >  application/config/geolocation.php  >  Download  
File: application/config/geolocation.php
Role: Configuration script
Content type: text/plain
Description: Configuration script
Class: CodeIgniter Geolocation Library
Get the location of an IP from a Web service
Author: By
Last change:
Date: 7 years ago
Size: 1,446 bytes
 

Contents

Class file image Download
<?php
defined
('BASEPATH') OR exit('No direct script access allowed');

/*
|--------------------------------------------------------------------------
| API URI
|--------------------------------------------------------------------------
|
| http://ipinfodb.com/ Offer a free IP Geolocation tools,
| The API returns the location of an IP address (country, region, city, zipcode,
| latitude, longitude) and the associated timezone in XML or JSON format.
|
*/
$config['api'] = 'http://api.ipinfodb.com/';

/*
|--------------------------------------------------------------------------
| API VERSION
|--------------------------------------------------------------------------
|
| Version of the API
|
*/
$config['api_version'] = 'v3';

/*
|--------------------------------------------------------------------------
| API KEY
|--------------------------------------------------------------------------
|
| The API KEY : You can get yours from here http://ipinfodb.com/register.php
|
*/
$config['api_key'] = 'YOUR_API_KEY_HERE';

/*
|--------------------------------------------------------------------------
| FORMAT
|--------------------------------------------------------------------------
|
| The default format is a php array, but you can change it to XML, JSON or RAW format
|
| $config['format'] = ''; Returns a PHP array
|
| $config['format'] = 'json';
|
| $config['format'] = 'xml';
|
| $config['format'] = 'raw';
|
*/
$config['format'] = '';

For more information send a message to info at phpclasses dot org.