Fix conditions
This commit is contained in:
parent
c57cb3fec7
commit
b2e18e40ac
1 changed files with 2 additions and 4 deletions
|
|
@ -76,13 +76,11 @@
|
|||
<?php $location = get_field( 'ort' ); ?>
|
||||
<?php $locations = get_field( 'orte' ); ?>
|
||||
<?php
|
||||
echo var_dump($location);
|
||||
echo "<br>";
|
||||
echo var_dump($locations);
|
||||
if ( $location && !$locations ){
|
||||
if ( $location && (!$locations || count($locations)==0) || is_nan($locations[0]['lat']) ) {
|
||||
$locations = [$location];
|
||||
}
|
||||
?>
|
||||
<?php $locations = get_field( 'orte' ); ?>
|
||||
<?php if ( $locations && count($locations)>0 && !is_nan($locations[0]['lat'])) : ?>
|
||||
<div class="post-meta">
|
||||
<div class='map' style='height:300px; margin-bottom: 1.6842em' id='map-<?php echo $id ?>-multiple'></div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue