Dear Reader, let us learn that How to “Create WordPress Page without Header / Footer / Sidebar“. And what contents you will be entered in the page editor, will only be displayed on website’s that particular page.
Step 1. Create a WordPress template file in public_html/wp-content/themes/ (your selected theme folder)
Create a php file, copy and paste the following code and save it as “template_without_header_footer_sidebar.php”.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
<?php /** * Template Name: Template without Header / Footer / Sidebar * Template will display only the contents you had entered in the page editor */ ?> <html <?php language_attributes(); ?> class="no-js"> <head> <meta charset="<?php bloginfo( 'charset' ); ?>"> <meta name="viewport" content="width=device-width, initial-scale=1"> <?php wp_head(); ?> </head> <body> <?php while ( have_posts() ) : the_post(); the_content(); endwhile; ?> <?php wp_footer(); ?> </body> </html> |
Step 2. Create a Page like Page without Header / Footer / Sidebar
From WordPress Admin panel Add New Page section, add a page which you want to display without Header / Footer / Sidebar.
Step 3. Select the template in the WordPress page editor
Select Page Attribute “Template” as “Template without Header / Footer / Sidebar” from Template’s drop-down list, in place of “Default Template”.
Finally, you can view the page contents on your website or localhost URL without Header / Footer / Sidebar.
Congratulations you have successfully learned How to “Create WordPress Page without Header / Footer / Sidebar”, if this post is helpful for you then please share this post on social media and if you have any query then please contact us or comment below and don’t forgot us to follow and like on Social Media, Thanks.
2 Comments:
chrome hearts April 25, 2018
I wish to point out my gratitude for your kind-heartedness for those people that have the need for help on this particular idea. Your personal commitment to getting the solution all through has been exceptionally valuable and have regularly enabled somebody just like me to attain their ambitions. Your valuable publication indicates a great deal a person like me and far more to my office workers. With thanks; from each one of us.
Webpreparations Team April 25, 2018
Thank you 🙂