Page 1 of 1

Remove Page Title Keep Category Title

Posted: 14 Apr 2010, 14:59
by likestuff
I'm trying to remove the page title from the category but when I do so from the "Parameters (Basic)" it removes the entire title. On the "List of Categories" page, the first page shows the titles ok, but when I click on a category the title looks like this:

Photo Gallery - Meeting at The Hilton Hotel (March 23, 2010)

What I want is:
Meeting at The Hilton Hotel (March 23, 2010)

I searched the forum but couldn't find an answer.

Thanks!!

Re: Remove Page Title Keep Category Title

Posted: 15 Apr 2010, 17:23
by Jan
Hi, you can set if only title of category or title of menu link + title of category will be displayed, see the Parameters System too.

Re: Remove Page Title Keep Category Title

Posted: 15 Apr 2010, 20:19
by likestuff
Hi Jan,

I must be a real blind bat :( I don't see the option to show ONLY the category name. I'm making these changes via the MENU.

Under Parameters (System)
- When I select Yes to "Show Page Title", I get this:
Photo Gallery - Meeting at The Hilton Hotel (March 23, 2010)

- When I select No to "Show Page Title", nothing shows - it's blank.

Under Parameters (Basic)
- When I choose "Hide" next to "Display Category Name in Page Title", I get this:
Photo Gallery

Re: Remove Page Title Keep Category Title

Posted: 24 Apr 2010, 22:47
by Jan
Hi, page title should be empty (parameters system)
Show page title should be set to YES (parameters system)

and Display Category Name in Page Title should be set to YES (in parameters basic)

In PHP language:

Code: Select all

// Heading
$heading = '';
if ($this->params->get( 'page_title' ) != '') {
    $heading .= $this->params->get( 'page_title' );
}
if ( $this->tmpl['displaycatnametitle'] == 1) {
    if ($this->category->title != '') {
        if ($heading != '') {
            $heading .= ' - ';
        }
        $heading .= $this->category->title;
    }
}
// Pagetitle
if ($this->tmpl['showpagetitle'] != 0) {
    if ( $heading != '') {
        echo '<div class="componentheading'.$this->params->get( 'pageclass_sfx' ).'">'.$heading.'</div>';
    } 
}