Overview

Packages

  • blesta
    • app
      • controllers
      • models
    • components
      • auth
        • ldap
        • motp
        • oath
      • delivery
        • interfax
        • postal
          • methods
      • download
      • email
      • events
      • exchange
        • rates
          • currency
            • layer
          • fixer
          • open
            • exchange
              • rates
          • x
            • rates
      • gateway
        • payments
      • gateways
      • invoice
        • delivery
        • templates
          • perforated
            • invoice
          • quickbooks
            • invoice
          • templates
            • default
      • modules
      • net
        • amazon
          • s3
        • http
        • net
          • geo
            • ip
      • plugins
      • reports
        • aging
          • invoices
        • client
          • data
            • portability
        • custom
          • report
        • invoice
          • creation
        • package
          • revenue
        • tax
          • liability
        • transactions
          • applied
          • received
      • security
      • session
        • cart
      • settingscollection
      • upgrades
        • tasks
      • upload
      • vcard
    • core
      • Automation
        • Tasks
          • Common
          • Task
        • Type
          • Common
          • Cron
      • Pricing
        • ItemComparator
        • MetaItem
        • Modifier
          • Type
            • Description
              • Type
                • Discount
                • Option
                • Service
                • Tax
            • Discount
            • Price
            • Proration
        • Presenter
          • Build
            • Invoice
            • InvoiceData
            • Options
            • Service
            • ServiceChange
            • ServiceData
          • Collection
          • Format
            • Fields
            • Type
              • Discount
              • Item
              • Option
              • Options
              • Package
              • Pricing
              • Service
              • Tax
          • Items
            • Invoice
            • Service
          • Type
      • ServiceProviders
      • Util
        • Captcha
          • Captchas
          • Common
        • Common
          • Traits
        • Events
          • Common
          • Handlers
          • Observers
        • Filters
          • Common
        • GeoIp
        • Input
          • Fields
            • Common
        • Tax
        • Widgets
    • helpers
      • currency
        • format
      • data
        • structure
          • array
          • string
      • text
        • parser
      • widget
        • client
  • minPHP
    • helpers
      • color
      • data
        • structure
  • None
  • PHP

Classes

  • AbstractGeoIp
  • GeoIp
  • GeoIp2
  • Overview
  • Package
  • Class
  • Tree
  • Deprecated

Class GeoIp2

GeoIP v2 integration

Blesta\Core\Util\GeoIp\AbstractGeoIp
Extended by Blesta\Core\Util\GeoIp\GeoIp2
Namespace: Blesta\Core\Util\GeoIp
Package: blesta\core\Util\GeoIp
Copyright: Copyright (c) 2019, Phillips Data, Inc.
License: The Blesta License Agreement
Link: Blesta
Located at core/Util/GeoIp/GeoIp2.php
Methods summary
public
# __construct( string $database_file )

Create a new GeoIP instance using the given database file

Create a new GeoIP instance using the given database file

Parameters

$database_file
The full path to the database file
public string
# getCountryCode( )

Returns the 2-character country code where the IP resides

Returns the 2-character country code where the IP resides

Returns

string
The 2-character country code where the IP resides
public string
# getCountryName( )

Returns the name of the country where the IP resides

Returns the name of the country where the IP resides

Returns

string
The name of the country where the IP resides
public array
# getLocation( )

Fetches an array of information about the location of the IP address, including longitude and latitude.

Fetches an array of information about the location of the IP address, including longitude and latitude.

Returns

array
An array of information about the location of the IP address
public string
# getRegion( )

Get the region (e.g. state) of the given IP address.

Get the region (e.g. state) of the given IP address.

Returns

string
The region the IP address resides in
public string
# getOrganization( )

Would get the organization or ISP that owns the current IP address. However this information is not available from the GeoIp2 city model

Would get the organization or ISP that owns the current IP address. However this information is not available from the GeoIp2 city model

Returns

string
public
# setIp( string $ip )

Sets the Ip address to use for all suybsequent queries

Sets the Ip address to use for all suybsequent queries

Parameters

$ip
The Ip address to set

Overrides

Blesta\Core\Util\GeoIp\AbstractGeoIp::setIp()
Methods inherited from Blesta\Core\Util\GeoIp\AbstractGeoIp
getIp()
Blesta API documentation generated by ApiGen