You are here

function theme_smart_ip_latitude_dms in Smart IP 8.3

Same name and namespace in other branches
  1. 8.4 smart_ip.module \theme_smart_ip_latitude_dms()
  2. 8.2 smart_ip.module \theme_smart_ip_latitude_dms()
  3. 6.2 smart_ip.module \theme_smart_ip_latitude_dms()
  4. 6 smart_ip.module \theme_smart_ip_latitude_dms()
  5. 7.2 smart_ip.module \theme_smart_ip_latitude_dms()
  6. 7 smart_ip.module \theme_smart_ip_latitude_dms()

Display latitude.

File

./smart_ip.module, line 129
Determines country, geo location (longitude/latitude), region, city and postal code of the user, based on IP address

Code

function theme_smart_ip_latitude_dms($variable) {
  $output = '';
  list($degrees, $minutes, $seconds, $negative) = coordinates_dd_to_dms($variable['latitude']);
  $output .= "{$degrees}° {$minutes}' {$seconds}\" ";
  if (!$negative) {
    $output .= 'N';
  }
  else {
    $output .= 'S';
  }
  return $output;
}