-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
48 lines (43 loc) · 1.17 KB
/
index.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
40
41
42
43
44
45
46
47
48
<?php
/**
* The Main template file
*
* That's the very basic file for any WP theme.
*
*
* Learn more: {@link https://codex.wordpress.org/Template_Hierarchy}
*
* @package Pesticide
* @since Pesticide 0.0.1
*/
get_header();
?>
<main class="pest-content">
<div class="pest-entry">
<?php
if (have_posts()) {
while(have_posts()) {
the_post();
get_template_part('template-parts/content', get_post_format());
}
} else {
get_template_part('template-parts/content', 'none');
}
?>
</div>
<div class="pest-pagination">
<?php if (function_exists('pest_pagination')) : ?>
<?php pest_pagination(); ?>
<?php elseif(is_paged()) : ?>
<nav class="pest-nav">
<div class="pest-nav__previous">
<?php next_posts_link(__('← Older posts', 'hlebarovpress')); ?>
</div>
<div class="pest-nav__next">
<?php previous_posts_link(__('Newer posts →', 'hlebarovpress')); ?>
</div>
</nav>
<?php endif; ?>
</div>
</main>
<?php get_footer(); ?>