You are here

function theme_location_latitude_dms in Location 7.5

Same name and namespace in other branches
  1. 5.3 location.module \theme_location_latitude_dms()
  2. 6.3 location.module \theme_location_latitude_dms()
  3. 7.3 location.module \theme_location_latitude_dms()
  4. 7.4 location.module \theme_location_latitude_dms()

Display a coordinate.

3 theme calls to theme_location_latitude_dms()
location_views_handler_field_coordinates::render in handlers/location_views_handler_field_coordinates.inc
Render the field.
location_views_handler_field_latitude::render in handlers/location_views_handler_field_latitude.inc
Render the field.
template_preprocess_location in ./location.module
Theme preprocess function for a location.

File

./location.module, line 1573
Location module main routines. An implementation of a universal API for location manipulation. Provides functions for postal_code proximity searching, deep-linking into online mapping services. Currently, some options are configured through an…

Code

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