Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * The template for displaying archive pages
- *
- * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
- *
- */
- get_header();
- ?>
- <div id="primary" class="content-area">
- <main id="main" class="site-main" role="main">
- <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
- <!-- custom template to show a single post title, author -->
- <div class="post-title">
- <a href="<?php echo esc_url(get_permalink()); ?>">
- <h4 class="text-title">
- <?php the_title(); ?>
- </h4>
- </a>
- <span>Post by <?php echo the_author_meta('display_name'); ?></span>
- </div>
- <?php
- endwhile; // end loop
- wp_reset_postdata(); // reset query
- else :
- get_template_part('template-parts/content', 'search-none');
- endif;
- ?>
- </div>
- </main><!-- #main -->
- </div>
- <?php
- get_footer();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement