forked from dingproject/dynamo
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlocation.tpl.php
More file actions
51 lines (48 loc) · 1.26 KB
/
location.tpl.php
File metadata and controls
51 lines (48 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<div class="location vcard">
<div class="adr">
<?php echo $name; ?>
<?php if ($street) {?>
<div class="street-address">
<?php
echo $street;
if ($additional) {
echo ' '. $additional;
}
?>
</div>
<?php }?>
<?php
if ($city || $province || $postal_code) {
$city_province_postal = array();
if ($city) {
$city_province_postal[] = '<span class="locality">'. $city .'</span>';
}
if ($province) {
$city_province_postal[] = '<span class="region">'. $province .'</span>';
}
if ($postal_code) {
$city_province_postal[] = '<span class="postal-code">'. $postal_code .'</span>';
}
echo implode(', ', $city_province_postal);
}
?>
<?php if ($country_name) { ?>
<div class="country-name"><?php echo $country_name; ?></div>
<?php } ?>
<?php
// "Geo" microformat, see http://microformats.org/wiki/geo
if ($latitude && $longitude) {
// Assume that 0, 0 is invalid.
if ($latitude != 0 || $longitude != 0) {
?>
<span class="geo">
<abbr class="latitude" title="<?php echo $latitude; ?>"><?php echo $latitude_dms; ?></abbr>,
<abbr class="longitude" title="<?php echo $longitude; ?>"><?php echo $longitude_dms; ?></abbr>
</span>
<?php
}
}
?>
</div>
</div>
<?php echo $map_link; ?>