Create reusable article card component and fix archive title prefixes
This commit is contained in:
17
index.php
17
index.php
@@ -23,22 +23,7 @@ get_header(); ?>
|
||||
while (have_posts()):
|
||||
the_post();
|
||||
?>
|
||||
<div class="col-md-6 col-lg-4 d-flex align-items-stretch">
|
||||
<article id="post-<?php the_ID(); ?>" <?php post_class('card w-100 border-0 shadow-sm h-100'); ?>>
|
||||
<div class="card-body d-flex flex-column">
|
||||
<header class="entry-header mb-3">
|
||||
<div class="entry-meta mb-2 small text-uppercase fw-bold text-muted">
|
||||
<?php echo get_the_category_list(', '); ?>
|
||||
</div>
|
||||
<?php the_title('<h3 class="card-title h5 fw-bold"><a href="' . esc_url(get_permalink()) . '" class="text-dark text-decoration-none stretched-link">', '</a></h3>'); ?>
|
||||
</header>
|
||||
|
||||
<div class="card-text text-muted flex-grow-1">
|
||||
<?php the_excerpt(); ?>
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
</div>
|
||||
<?php get_template_part('template-parts/content', 'card'); ?>
|
||||
<?php
|
||||
endwhile;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user