Revert changes as Urlaub is a category and not a post-type

This commit is contained in:
Markus Ankenbrand 2016-09-10 20:27:33 +02:00
parent 456f2ccfef
commit 48cd36e98b
3 changed files with 55 additions and 190 deletions

View file

@ -48,6 +48,48 @@
<div class="clear"></div>
<?php if ( get_the_category()[0]->name == 'Urlaub' ) : ?>
<div class="post-meta">
<table>
<tr>
<th>Land</th>
<td><?php the_field( 'land' ) ?></td>
</tr>
<tr>
<th>Mitreisende</th>
<td><?php the_field( 'mitreisende' ) ?></td>
</tr>
<tr>
<th>Anreise</th>
<td><?php $an = get_field( 'anreise' ); echo(substr($an,6,2).'.'.substr($an,4,2).'.'.substr($an,0,4)) ?></td>
</tr>
<tr>
<th>Abreise</th>
<td><?php $ab = get_field( 'abreise' ); echo(substr($ab,6,2).'.'.substr($ab,4,2).'.'.substr($ab,0,4)) ?></td>
</tr>
</table>
</div>
<div class="post-meta">
<?php $location = get_field( 'ort' ); ?>
<div class='map' style='height:300px; margin-bottom: 1.6842em' id='map-<?php echo $id ?>'></div>
<script type='text/javascript'>
var map;
var map_center = {lat: <?php echo $location['lat'] ?>, lng: <?php echo $location['lng'] ?> };
function initMap() {
map = new google.maps.Map(document.getElementById('map-<?php echo $id ?>'), {
center: map_center,
zoom: 15
});
var marker = new google.maps.Marker({
position: map_center,
map: map
});
}
</script>
</div>
<?php endif; ?>
<?php
$args = array(
'before' => '<div class="page-links"><span class="title">' . __( 'Pages:','hitchcock' ) . '</span>',