summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--location.tpl.php21
1 files changed, 9 insertions, 12 deletions
diff --git a/location.tpl.php b/location.tpl.php
index 4b80fc1..0acf692 100644
--- a/location.tpl.php
+++ b/location.tpl.php
@@ -9,20 +9,17 @@
?></div>
<?php }?>
<?php
- if ($city || $province || $postal_code) {
- $city_province_postal = array();
-
- if ($city) {
- $city_province_postal[] = '<span class="locality">'. $city .'</span>';
- }
+ if ($city) {
+ echo '<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 ', ';
}
-
- echo implode(', ', $city_province_postal);
+ }
+ if ($province) {
+ echo '<span class="region">' . $province . '</span> ';
+ }
+ if ($postal_code) {
+ echo ' <span class="postal-code">' . $postal_code . '</span>';
}
?>
<?php if ($country_name) { ?>