You are here

function _hosting_ip_view in Hosting 7.3

Same name and namespace in other branches
  1. 7.4 server/hosting.ip.inc \_hosting_ip_view()

Display the ip address on the node. IP utility function for hook_view.

1 call to _hosting_ip_view()
hosting_server_view in server/hosting_server.module
Implements hook_view().

File

server/hosting.ip.inc, line 10
General IP address CRUD routines.

Code

function _hosting_ip_view(&$node) {
  $ip_list = isset($node->ip_addresses) ? $node->ip_addresses : array();
  if (sizeof($ip_list)) {
    $node->content['info']['ip_addresses'] = array(
      '#type' => 'item',
      '#title' => t('IP addresses'),
      '#markup' => implode('<br />', $ip_list),
    );
  }
}