You are here

function domain_views_handler_argument_domain_access_gid::get_domain_id in Domain Views 7

3 calls to domain_views_handler_argument_domain_access_gid::get_domain_id()
domain_views_handler_argument_domain_access_gid::summary_argument in includes/domain_views_handler_argument_domain_access_gid.inc
Provide the argument to use to link from the summary to the next level.
domain_views_handler_argument_domain_access_gid::summary_name in includes/domain_views_handler_argument_domain_access_gid.inc
Provides the name to use for the summary.
domain_views_handler_argument_domain_access_gid::title in includes/domain_views_handler_argument_domain_access_gid.inc
Get the title this argument will assign the view, given the argument.

File

includes/domain_views_handler_argument_domain_access_gid.inc, line 46
Interface between domain_views.module and views.module.

Class

domain_views_handler_argument_domain_access_gid
Argument for domain ids stored in the database currently active domain and any domain.

Code

function get_domain_id($domain_id) {
  $domains = domain_domains();
  foreach ($domains as $domain) {
    $domain_options[$domain['domain_id']] = $domain['sitename'];
  }
  return isset($domain_options[$domain_id]) ? $domain_options[$domain_id] : t('Unknown domain');
}