-
Notifications
You must be signed in to change notification settings - Fork 1
/
archive-product.php
36 lines (34 loc) · 1.14 KB
/
archive-product.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
<?php get_header(); ?>
<h2 class="page-heading">All Products</h2>
<section>
<?php
while (have_posts()) {
the_post();
?>
<div class="card">
<div class="card-image">
<a href="<?php echo the_permalink();?>">
<img src="<?php echo get_the_post_thumbnail_url(get_the_ID()); ?>"
alt="Card Image">
</a>
</div>
<div class="card-description">
<a href="<?php echo the_permalink();?>">
<h3><?php echo the_title();?></h3>
</a>
<div class="card-meta">
Posted by <?php the_author(); ?> on <?php the_time('F j, Y') ?>
</div>
<p>
<?php echo wp_trim_words(get_the_excerpt(), 36);?>
</p>
<a href="<?php echo the_permalink();?>" class="btn-readmore">Read more</a>
</div>
</div>
<?php }
wp_reset_query(); ?>
</section>
<div class="pagination">
<?php echo paginate_links(); ?>
</div>
<?php get_footer(); ?>