Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

geoip_netspeedcell_by_name(3) [php man page]

GEOIP_NETSPEEDCELL_BY_NAME(3)						 1					     GEOIP_NETSPEEDCELL_BY_NAME(3)

geoip_netspeedcell_by_name - Get the Internet connection speed

SYNOPSIS
string geoip_netspeedcell_by_name (string $hostname) DESCRIPTION
The geoip_netspeedcell_by_name(3) function will return the Internet connection type and speed corresponding to a hostname or an IP address. This function is only available if using GeoIP Library version 1.4.8 or newer. This function is currently only available to users who have bought a commercial GeoIP NetSpeedCell Edition. A warning will be issued if the proper database cannot be located. The return value is a string, common values are: o Cable/DSL o Dialup o Cellular o Corporate PARAMETERS
o $hostname - The hostname or IP address. RETURN VALUES
Returns the connection speed on success, or FALSE if the address cannot be found in the database. EXAMPLES
Example #1 A geoip_netspeedcell_by_name(3) example This will output the connection speed of the host example.com. <?php $netspeed = geoip_netspeedcell_by_name('www.example.com'); if ($netspeed) { echo 'The connection type is: '. $netspeed; } ?> The above example will output: The connection type is: Corporate PHP Documentation Group GEOIP_NETSPEEDCELL_BY_NAME(3)

Check Out this Related Man Page

GEOIP_RECORD_BY_NAME(3) 						 1						   GEOIP_RECORD_BY_NAME(3)

geoip_record_by_name - Returns the detailed City information found in the GeoIP Database

SYNOPSIS
array geoip_record_by_name (string $hostname) DESCRIPTION
The geoip_record_by_name(3) function will return the record information corresponding to a hostname or an IP address. This function is available for both GeoLite City Edition and commercial GeoIP City Edition. A warning will be issued if the proper data- base cannot be located. The names of the different keys of the returning associative array are as follows: o "continent_code" -- Two letter continent code (as of version 1.0.4 with libgeoip 1.4.3 or newer) o "country_code" -- Two letter country code (see geoip_country_code_by_name(3)) o "country_code3" -- Three letter country code (see geoip_country_code3_by_name(3)) o "country_name" -- The country name (see geoip_country_name_by_name(3)) o "region" -- The region code (ex: CA for California) o "city" -- The city. o "postal_code" -- The Postal Code, FSA or Zip Code. o "latitude" -- The Latitude as signed double. o "longitude" -- The Longitude as signed double. o "dma_code" -- Designated Market Area code (USA and Canada only) o "area_code" -- The PSTN area code (ex: 212) PARAMETERS
o $hostname - The hostname or IP address whose record is to be looked-up. RETURN VALUES
Returns the associative array on success, or FALSE if the address cannot be found in the database. CHANGELOG
+--------+---------------------------------------------------+ |Version | | | | | | | Description | | | | +--------+---------------------------------------------------+ | 1.0.4 | | | | | | | Adding the continent_code with GeoIP Library | | | 1.4.3 or newer only | | | | | 1.0.3 | | | | | | | Adding country_code3 and country_name | | | | +--------+---------------------------------------------------+ EXAMPLES
Example #1 A geoip_record_by_name(3) example This will print the array containing the record of host example.com. <?php $record = geoip_record_by_name('www.example.com'); if ($record) { print_r($record); } ?> The above example will output: Array ( [continent_code] => NA [country_code] => US [country_code3] => USA [country_name] => United States [region] => CA [city] => Marina Del Rey [postal_code] => [latitude] => 33.9776992798 [longitude] => -118.435096741 [dma_code] => 803 [area_code] => 310 ) PHP Documentation Group GEOIP_RECORD_BY_NAME(3)
Man Page