function post_find_by_tid($tid, $pagesize = 0) { global $conf; empty($pagesize) and $pagesize = $conf['postlist_pagesize']; $key = "postlist_{$tid}"; $postlist = cache_get($key); if ($postlist === NULL) { $postlist = post__find(array('tid' => $tid), array('pid' => 1), 1, $pagesize); cache_set($key, $postlist); } if ($postlist) { $floor = 0; foreach ($postlist as &$post) { $post['floor'] = $floor++; post_format($post); } } return $postlist; }
<header class="page-header"> <?php the_archive_title('<h1 class="page-title">', '</h1>'); the_archive_description('<div class="taxonomy-description">', '</div>'); ?> </header><!-- .page-header --> <?php /* Start the Loop */ while (have_posts()) { the_post(); /* * Include the Post-Format-specific template for the content. * If you want to override this in a child theme, then include a file * called content-___.php (where ___ is the Post Format name) and that will be used instead. */ get_template_part('templates/template-parts/content', get_post_format()); echo post_format(); } the_posts_navigation(); } else { get_template_part('templates/template-parts/content', 'none'); } ?> </main><!-- #main --> </div><!-- #primary --> <?php get_sidebar(); get_footer();