Forums

Remove Sidebars (6 posts)

  1. jostoga
    Member
    Posted 9 months ago #

    Hi!
    How can I remove SIDEBARS from one particular page?
    I use this theme: http://newwpthemes.com/wordpress-theme/permanent/

    Thanks

  2. peredur
    Member
    Posted 9 months ago #

    Create a page-permanent.php file that outputs the layout you want.

    See the WordPress Template Hierarchy.

    I'd copy the contents of page.php into it as a starter and then mess with it until it provided what I wanted.

    Cheers

    PAE

  3. netxm
    Member
    Posted 9 months ago #

    in your page.php replace get_sidebar() with this, and replace your_id with page ID number:

    if (!is_page('your_id')) {
    get_sidebar();
    }
  4. jvyda
    Member
    Posted 9 months ago #

    you could make a copy of the page template and then remove the get_sidebar() from that page and save it. While adding the page, where you do not need the side bar select the template file you just created from the drop down and you are done.

    adding the code which "netxm" suggests to the page would allow you to get the sidebar instead of ignoring it.

  5. jostoga
    Member
    Posted 9 months ago #

    How can I add a new template, when I do not have DROP DOWN menu there?
    Thanks

  6. netxm
    Member
    Posted 9 months ago #

    create new file in your theme

    you-page.php and put this on top of your page

    <?php 
    
    /** Template Name: Your Template **/
    
    ?>

Reply

You must log in to post.

About this Topic

Tags

No tags yet.