-
Notifications
You must be signed in to change notification settings - Fork 1
/
archive-jetpack-testimonial.php
62 lines (42 loc) · 1.54 KB
/
archive-jetpack-testimonial.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<?php
/**
* Archive for testimonials.
*
* @package Chuchadon
*/
get_header(); ?>
<?php if ( have_posts() ) : ?>
<div id="testimonial-area" class="testimonial-area front-page-area">
<?php // Get Jetpack testimonial options.
$jetpack_options = get_theme_mod( 'jetpack_testimonials' );
?>
<?php if ( '' != wp_get_attachment_image( (int)$jetpack_options['featured-image'], 'full' ) ) : ?>
<div class="entry-content">
<?php
echo '<p>' . wp_get_attachment_image( (int)$jetpack_options['featured-image'], 'full' ) . '</p>';
?>
</div>
<?php endif; ?>
<div class="testimonial-wrapper">
<?php do_action( 'chuchadon_before_loop' ); // Action hook before loop. ?>
<?php /* Start the Loop */ ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php
/* Load content-jetpack-testimonial template. */
get_template_part( 'template-parts/content', 'jetpack-testimonial' );
?>
<?php endwhile; ?>
</div><!-- .testimonial-wrapper -->
</div><!-- #testimonial-area -->
<?php
the_posts_pagination( array(
'prev_text' => __( 'Previous page', 'chuchadon' ),
'next_text' => __( 'Next page', 'chuchadon' ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'chuchadon' ) . ' </span>',
) );
?>
<?php else : ?>
<?php get_template_part( 'template-parts/content', 'none' ); ?>
<?php endif; ?>
<?php do_action( 'chuchadon_after_loop' ); // Action hook after loop. ?>
<?php get_footer(); ?>