location_views_handler_field_coordinates.inc in Location 7.3
Same filename and directory in other branches
Coordinates field handler.
File
handlers/location_views_handler_field_coordinates.incView source
<?php
/**
* @file
* Coordinates field handler.
*/
// @codingStandardsIgnoreStart
class location_views_handler_field_coordinates extends location_views_handler_field_latitude {
/**
* {@inheritdoc}
*/
public function construct() {
parent::construct();
$this->additional_fields['longitude'] = 'longitude';
}
/**
* {@inheritdoc}
*/
public function render($values) {
if ($this->options['style'] == 'dms') {
return theme('location_latitude_dms', array(
'latitude' => $values->{$this->field_alias},
)) . ', ' . theme('location_longitude_dms', array(
'longitude' => $values->{$this->aliases['longitude']},
));
}
else {
return check_plain($values->{$this->field_alias}) . ', ' . check_plain($values->{$this->aliases['longitude']});
}
}
}
// @codingStandardsIgnoreEnd
Classes
Name | Description |
---|---|
location_views_handler_field_coordinates |