WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] How to safely remove auto "private" header in private pages - twenty fourteen (3 posts)

  1. Paulnicole
    Member
    Posted 5 months ago #

    Hi

    I just resolved a big drama on my site after attempting that the wrong way.

    In twenty fourteen - what is the BESt way to adapt the PRIVATE pages so they don't show the word PRIVATE in the header?

    Is a plug in the way to go and if so which is recommended?

    Thanks

    PS I'm asking here becuase internet advice and old posts is partly contradictory

  2. Dave Naylor
    Member
    Posted 5 months ago #

    Try this. It goes in your functions.php file (Be careful! :))

    function title_format($content) {
       return '%s';
    }
    add_filter('private_title_format', 'title_format');
    add_filter('protected_title_format', 'title_format');
  3. Paulnicole
    Member
    Posted 5 months ago #

    Awesome. Thanks very much for both helping me restore my site after I wrecked it (see http://wordpress.org/support/topic/twenty-fourteen-template-inoperable-after-minor-change-to-functionsphp?replies=5),
    for teaching me the virtues of FTP, and solving my original query :)

Reply

You must log in to post.

About this Topic