You are here

function countries_admin_page in Countries 7.2

Same name and namespace in other branches
  1. 8 countries.admin.inc \countries_admin_page()
  2. 7 countries.admin.inc \countries_admin_page()

Menu callback; Display a country form.

1 string reference to 'countries_admin_page'
countries_menu in ./countries.module
Implements hook_menu().

File

./countries.admin.inc, line 87
Admin page callbacks for the Countries module.

Code

function countries_admin_page($country = NULL) {

  // Menu callbacks and local actions do not have page titles.
  if (isset($country)) {
    drupal_set_title(t('Edit country %title', array(
      '%title' => $country->name,
    )), PASS_THROUGH);
  }
  else {
    drupal_set_title(t('Add country'), PASS_THROUGH);
    $country = country_create();
  }
  return drupal_get_form('countries_admin_form', $country);
}