forked from codemonkey-jack/shoestrap-3
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
43 lines (35 loc) · 1.18 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
<?php
if ( !has_action( 'shoestrap_page_header_override' ) )
get_template_part('templates/page', 'header');
else
do_action( 'shoestrap_page_header_override' );
do_action( 'shoestrap_index_begin' );
if ( !have_posts() ) :
echo '<div class="alert alert-warning">';
_e('Sorry, no results were found.', 'roots');
echo '</div>';
get_search_form();
endif;
if ( !has_action( 'shoestrap_override_index_loop' ) ) :
while (have_posts()) : the_post();
do_action( 'shoestrap_in_loop_start_action' );
do_action( 'shoestrap_before_the_content' );
if ( !has_action( 'shoestrap_content_override' ) )
get_template_part('templates/content', get_post_format());
else
do_action( 'shoestrap_content_override' );
do_action( 'shoestrap_after_the_content' );
endwhile;
else :
do_action( 'shoestrap_override_index_loop' );
endif;
do_action( 'shoestrap_index_end' );
if ($wp_query->max_num_pages > 1) : ?>
<nav class="post-nav">
<ul class="pager">
<li class="previous"><?php next_posts_link(__('← Older posts', 'roots')); ?></li>
<li class="next"><?php previous_posts_link(__('Newer posts →', 'roots')); ?></li>
</ul>
</nav>
<?php
endif;