- if ($sOSMType) echo ' osm_type="'.$sOSMType.'"'.' osm_id="'.$aPlace['osm_id'].'"';
- if ($aPlace['ref']) echo ' ref="'.htmlspecialchars($aPlace['ref']).'"';
- if (isset($aPlace['lat'])) echo ' lat="'.htmlspecialchars($aPlace['lat']).'"';
- if (isset($aPlace['lon'])) echo ' lon="'.htmlspecialchars($aPlace['lon']).'"';
+ if ($sOSMType) {
+ echo ' osm_type="'.$sOSMType.'"'.' osm_id="'.$aPlace['osm_id'].'"';
+ }
+ if ($aPlace['ref']) {
+ echo ' ref="'.htmlspecialchars($aPlace['ref']).'"';
+ }
+ if (isset($aPlace['lat'])) {
+ echo ' lat="'.htmlspecialchars($aPlace['lat']).'"';
+ }
+ if (isset($aPlace['lon'])) {
+ echo ' lon="'.htmlspecialchars($aPlace['lon']).'"';
+ }