Title don't showingup

Phoca Guestbook - creating guestbooks in Joomla! CMS
kycu
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 22 Jul 2012, 18:01

Title don't showingup

Post by kycu »

Hello

I've got J! 2.5 and new Phoca Guestbook.

I setup guestbook into website menu and guestbook title don't showingup over whole book (like componentheading should). I don't know why. It's a fresh install. Even in menu parametrs I set "Show menu title: Yes" it doesn't work.

Another problem. Why guestbook title don't show webpage name on top web browser bar? i've got set in global configuration to show website name before articles, components titles... but it shows me only a guestbook name :roll: without webpage name...

I can't show website. It's on my localhost computer

Thanks for help,
Peter
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48743
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Title don't showingup

Post by Jan »

Hi, you can customize the displaying of the title here:

components\com_phocaguestbook\views\guestbook\tmpl\default.php

Jan
If you find Phoca extensions useful, please support the project
kycu
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 22 Jul 2012, 18:01

Re: Title don't showingup

Post by kycu »

Thanks for answer Jan

but in file default.php exist code

Code: Select all

if ( $this->params->get( 'show_page_heading' ) ) { 
	echo '<h1>'. $this->escape($this->params->get('page_heading')) . '</h1>';
}
but doesn't work well! I don't know why.

So I added own code to resolve my problem ;) I repair it on example from another component so I add code after this

Code: Select all

// - - - - - - - - - - -
// Header
// - - - - - - - - - - -
echo '<div id="phocaguestbook" class="guestbook'.$this->params->get( 'pageclass_sfx' ).'">';
added

Code: Select all

$document =& JFactory::getDocument(); 
$app	= JFactory::getApplication();

$gbtitle = $document->getTitle();
$title = $app->getCfg('sitename') .' - '. $document->getTitle();
$document->setTitle( $title); 

echo '<h1 class="guestbook-title">' . $gbtitle . '</h1>';
Maybe it helps someone :)
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48743
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Title don't showingup

Post by Jan »

Ok
If you find Phoca extensions useful, please support the project
Post Reply