Newer
Older
Digital_Repository / Repositories / statistics / includes / inc.fns.show_detail_country.es.php
<?php
/*
	Usage by country, totals.

*/

	include("inc.fns.geoip.php");
	
	$gi = new GeoIP;

	// Get detail given country
	$show_country = $_REQUEST["code"];
	$show_country_code = strtoupper($show_country);
	
	if ($show_country_code == 'T5')
	{
		$show_country_name = $GLOBALS["config_vars"]["general"]["local_intranet_name"];
	}
	else if (isset($gi->GEOIP_COUNTRY_CODE_TO_NUMBER[$show_country_code]))
	{
		$show_country_num = $gi->GEOIP_COUNTRY_CODE_TO_NUMBER[$show_country_code];
		$show_country_name = $gi->GEOIP_COUNTRY_NAMES[$show_country_num];
	}
	else
	{	
		$show_country_name = 'Unknown';
	}

	$GLOBALS["db_values"] = $sql->getArchiveCountCountry($_REQUEST["code"]);
?>