Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /***** Create page.php in WordPress *****/
- ---write the following code between the main div of theme like wrapper/maincontent---
- <?php get_header(); ?>
- <div id="primary" class="content-area">
- <main id="main" class="site-main" role="main">
- <?php
- // Start the loop.
- while ( have_posts() ) : the_post();
- // Include the page content template.
- get_template_part( 'content', 'page' );
- // If comments are open or we have at least one comment, load up the comment template.
- if ( comments_open() || get_comments_number() ) :
- comments_template();
- endif;
- // End the loop.
- endwhile;
- ?>
- </main><!-- .site-main -->
- </div><!-- .content-area -->
- <?php get_footer(); ?>
Add Comment
Please, Sign In to add comment