You are here

function uc_country_get_by_id in Ubercart 7.3

Same name and namespace in other branches
  1. 6.2 uc_store/uc_store.module \uc_country_get_by_id()

Retrieves a country's name from the database, using its ID.

Parameters

$id: The country's ISO 3166-1 numeric identifier.

1 call to uc_country_get_by_id()
uc_usps_country_map in shipping/uc_usps/uc_usps.countries.inc
Returns the country name formatted according to the USPS requirements.

File

uc_store/uc_store.module, line 1369
Contains global Ubercart functions and store administration functionality.

Code

function uc_country_get_by_id($id) {
  return db_query("SELECT country_name FROM {uc_countries} WHERE country_id = :id", array(
    ':id' => $id,
  ))
    ->fetchField();
}