Support » Fixing WordPress » URGENT, how to have a particular post without siderbar and Header Title ?

  • Hey ,
    I want to to have a particular post without sidebar and header title, this is for one post only, the theme is magazine basic
    my website is

    plz tell me how to do it, URGENT

    How to create a separate post template without sidebar and footer and title heading

Viewing 14 replies - 1 through 14 (of 14 total)
  • jack randall


    you’ll need to create a page template and tweak the contents of the file, read this for some pointers…

    yeah how to create a single.php file, and what codes to put in ti so that the sidebar, website title and footer contents are not present in that particular post .

    Plz tell me what codes to put on it, i am just new to coding.

    jack randall


    copy the page.php file (a page might be better to use) for this and create a new txt file, paste in the contents. save the new file as my_custom_page.php then add in the following the very top of the file

    Template Name: my_custom_page

    then upload this file to your theme folder.

    go to your dashboard and create a new page, select the page template using the dropdown menu on the right hand side and click publish.

    navigate to the page in your site and then start making changes to the new template file using appearance -> themes -> editor. (select your theme if it’s not already set) and click on my_custom_page.php on the right handside and start taking stuff out and seeing if that works…. save the file to see your changes.

    (*** make sure that you keep track of the things you cahnge, if you need to add them back in then keep open the original text file you created as a back up ***)

    thanks, i am testing it…

    jack randall


    cool, hope it works 😀

    hey , i just uploaded it , and it uploaded fine, but the header title and sidebar, footer All are still visible in this my_custom_page.php

    what might be the issue ??

    jack randall


    right, thats the next step. if you’ve added it to the page then publish the page and view it.

    open another tab in your browser so you can edit the template file my_custom_page.php

    so appearance -> themes -> editor. select the my_custom_page,php file in the list on the right and it should open the code editor in the main panel.

    you’re looking for php shortcodes like

    <?php get_sidebar(); ?>

    you can either delete these (not advisable) or comment them out by adding

    /* */

    inside the php tags like this

    <?php /*get_sidebar();*/ ?>`

    do the same for things like the footer. not too sure about the header title, what theme are you using?

    i am using magazine basic theme , of wordpress

    the total code which i copied from page.php was

    <?php get_header(); ?>
    	<?php get_template_part( 'loop', 'page' ); ?>
    <?php get_footer(); ?>

    that was the total code in it, there is no get_sidebar, why that cud be ?



    Forum Moderator

    to have a particular post without sidebar and header title, this is for one post only,

    please post a direct link to this one post;

    you might be able to do this with css alone – not ideal, but possibly faster than editing templates.

    ok that post is THIS



    Forum Moderator


    .page-id-88 #sidebar { display:none; }
    .page-id-88 #leftcontent{ margin-left:110px; }


    .page-id-88 #sidebar{ display:none; }
    .page-id-88 #leftcontent{ width:98%; }

    you need to repair some broken code in the header, as the #header div does not seem to be closed; possibly some others as well;

    validation report

    sorry plz i don’t get it ^ , what exactly to do ?

    Hi, I am also having the same problem.
    @ Aniee the .page-id-88 code goes in your css stylesheet.

    I was moving around the sidebars trying to take them out of the footer where they had been and put them into the index.php so I could use <?php get_sidebar(); ?> and not put it on the single.php

    this is the code I had in my footer

    		$loc = pbt_theme_option('sidebar_location');
    		if($loc==2 || $loc==4) {
    			get_sidebar(); // calling the First Sidebar
    		if(pbt_theme_option('sidebar_width2')!=0 && $loc!=3) get_sidebar( "second" ); // calling the Second Sidebar

    Any ideas how I can set this up so I can comment out the sidebars on single page? The site is

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘URGENT, how to have a particular post without siderbar and Header Title ?’ is closed to new replies.