forked from oeco/ekuatorial
-
Notifications
You must be signed in to change notification settings - Fork 0
/
loop-dataset.php
39 lines (39 loc) · 1.27 KB
/
loop-dataset.php
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
<div class="eight columns">
<ul class="list-datasets">
<?php while(have_posts()) : the_post(); ?>
<li id="post-<?php the_ID(); ?>" <?php post_class('post-item row'); ?>>
<article class="clearfix">
<?php
if(has_post_thumbnail()) {
echo '<a href="' . get_permalink() .'" title="' . get_the_title() . '">' . get_the_post_thumbnail($post->ID, 'map-thumb') . '</a>';
}
?>
<header class="post-header">
<h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
</header>
<section>
<?php the_excerpt(); ?>
<a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>" class="button"><?php _e('View this data', 'ekuatorial'); ?></a>
<?php
$data = get_field('full_download');
if($data) :
?>
<a href="<?php echo $data; ?>" class="button download"><?php _e('Download', 'ekuatorial'); ?></a>
<?php
endif;
?>
<?php
$data = get_field('source_url');
if($data) :
?>
<a href="<?php echo $data; ?>" class="button download"><?php _e('Download from source', 'ekuatorial'); ?></a>
<?php
endif;
?>
</section>
</article>
</li>
<?php endwhile; ?>
</ul>
<?php if(function_exists('wp_paginate')) wp_paginate(); ?>
</div>