ThemeShaper Forums » Thematic

[closed]

Can I remove Private from the title of one page?

(3 posts)
  • Started 14 years ago by RoseyDow
  • Latest reply from Caramboo
  • This topic is not resolved
  1. I have a page that I don't want to appear in the menu bar, so I made it private. However, the word Private: appears on the title of the page itself. How can I get that off?

    Thanks,
    Rosey Dow

    Posted 14 years ago #
  2. Jamie Mitchell
    Member

    don't set it to private...

    instead get the exclude pages widget

    Posted 14 years ago #
  3. Caramboo
    Member

    Just found this:


    function the_title_trim($title) {

    $title = attribute_escape($title);

    $findthese = array(
    '#Protected:#',
    '#Private:#'
    );

    $replacewith = array(
    '', // What to replace "Protected:" with
    '' // What to replace "Private:" with
    );

    $title = preg_replace($findthese, $replacewith, $title);
    return $title;
    }
    add_filter('the_title', 'the_title_trim');

    Place it in your functions file. (I haven't tested it yet).

    Posted 14 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.