Support » Plugins » different sidebars on password protected page

  • I have a password protected page without a sidebar on the login page. Once a user has logged in then the sidebar is revealed. The code I use for this in the page template is:
    <?php
    if ( !post_password_required() ) {
    include(TEMPLATEPATH . ‘/sidebar5.php’);
    }
    ?>

    I would now like to modify this and display a different sidebar on the login page for some general info. I have tried adding to the above:
    else
    {
    include(TEMPLATEPATH . ‘/sidebar-password.php’);
    }

    Nothing happens though. It still works but the login page still doesn’t show the alternate sidebar.

    Any ideas? Thanks in advance.

  • The topic ‘different sidebars on password protected page’ is closed to new replies.