forked from cohhe/shopera
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfeatured-content.php
More file actions
executable file
·68 lines (59 loc) · 1.65 KB
/
featured-content.php
File metadata and controls
executable file
·68 lines (59 loc) · 1.65 KB
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
63
64
65
66
67
68
<?php
/**
* The template for displaying featured content
*
* @package WordPress
* @subpackage Shopera
* @since Shopera 1.0
*/
?>
<div class="featured-slider">
<div id="featured-content" class="featured-content swiper-container">
<div class="featured-content-inner swiper-wrapper">
<?php
/**
* Fires before the Shopera 1.0 featured content.
*
* @since Shopera 1.0
*/
do_action( 'shopera_featured_posts_before' );
$featured_posts = shopera_get_featured_posts();
foreach ( (array) $featured_posts as $order => $post ) :
setup_postdata( $post );
// Include the featured content template.
get_template_part( 'content', 'featured-post' );
endforeach;
/**
* Fires after the Shopera 1.0 featured content.
*
* @since Shopera 1.0
*/
do_action( 'shopera_featured_posts_after' );
wp_reset_postdata();
?>
</div><!-- .featured-content-inner -->
</div><!-- #featured-content .featured-content -->
<div class="featured-content-side">
<?php
/**
* Fires before the Shopera 1.0 featured content.
*
* @since Shopera 1.0
*/
do_action( 'shopera_featured_posts_before' );
$featured_posts = shopera_get_featured_side_posts();
foreach ( (array) $featured_posts as $order => $post ) :
setup_postdata( $post );
// Include the featured content template.
get_template_part( 'content', 'featured-side-post' );
endforeach;
/**
* Fires after the Shopera 1.0 featured content.
*
* @since Shopera 1.0
*/
do_action( 'shopera_featured_posts_after' );
wp_reset_postdata();
?>
</div>
</div><!-- .featured-slider -->