Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * The template for displaying archive pages
- *
- * @link https://codex.wordpress.org/Template_Hierarchy
- *
- * @package balinews_Default_Theme
- */
- get_header(); ?>
- <div class="left-column">
- </div>
- <div id="primary" class="content-area">
- <main id="main" class="site-main" role="main">
- <div class="archive-page">
- <div class="container">
- <div class="row">
- <div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-xs-12">
- <?php the_archive_title( '<h1 class="page-title">', '</h1>' ); ?>
- <!-- Show posts -->
- <?php
- $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
- $args = array(
- 'paged'=> $paged,
- 'posts_per_page'=> 10,
- 'post_status' => 'publish'
- );
- query_posts($args); ?>
- <?php if ( have_posts() ) : while (have_posts()) : the_post();
- get_template_part( 'template-parts/content', get_post_format() );
- endwhile; ?>
- <!-- pagination -->
- <div class="navigation-page">
- <div class="prev-page">
- <?php previous_posts_link(); ?>
- </div>
- <div class="next-page">
- <?php next_posts_link(); ?>
- </div>
- </div>
- <?php else : ?>
- <p><?php _e('tidak ada berita tersedia'); ?></p>
- <?php endif; ?>
- <!-- Show posts -->
- </div>
- </div>
- </div>
- </div>
- </main><!-- #main -->
- </div><!-- #primary -->
- <?php
- get_footer();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement