change entry display = edition of default.php

Phoca Guestbook - creating guestbooks in Joomla! CMS
dotcom22
Phoca Enthusiast
Phoca Enthusiast
Posts: 54
Joined: 10 Nov 2008, 18:19

change entry display = edition of default.php

Post by dotcom22 »

hello Jan

I would like customize little bit the entry display of guestbook. I have edit the file default.php located on /public_html/components/com_phocaguestbook/views/phocaguestbook/tmpl .

I found at line 112 and line 165 the follow code who seem manage entry display:

Code: Select all

Line 112

	$msgpg .= '<div style="border:1px solid '.$this->css['bordercolor'].';color:'.$this->css['fontcolor'].';margin:10px 0px;">';

	$msgpg .= '<h4 style="background:'.$this->css['backgroundcolor'].';color:'.$this->css['fontcolor'].';padding:8px;margin:2px;">';

Line 165

	$msgpg .= '</h4>';

	$msgpg .= '<div style="overflow:auto; border-left:5px solid '.$this->css['backgroundcolor'].'; padding-left:5px;margin:10px;">' . $values->content . $end_quote .$end_a. '</div>';

	$msgpg .= '<p align="right" style="padding-right:10px;"><small style="color:'.$this->css['secondfontcolor'].'">' . JHTML::_('date',  $values->date, JText::_( $this->tmpl['date_format'] ) ) . '</small>';

My goal is simply add a line between each entry for make a clear separation and nothing more. I have also remove the code making different color of some element. Now what I would like is to put in BOLD the writer name and subject of entry (instead using h4 header) but I don't see how to do...

Here my modified code with I am happy with it...is just missing the bold effect:

Code: Select all

Line 112

	$msgpg .= '<div style="border-bottom:1px solid '.$this->css['bordercolor'].';color:'.$this->css['fontcolor'].';margin:10px 0px;">';

Line 165

	$msgpg .= '</h4>';

	$msgpg .= '<div style="overflow:auto; border-left:0px solid '.$this->css['backgroundcolor'].'; padding-left:5px;margin:10px;">' . $values->content . $end_quote .$end_a. '</div>';

	$msgpg .= '<p align="right" style="padding-right:10px;">' . JHTML::_('date',  $values->date, JText::_( $this->tmpl['date_format'] ) ) . '</p>';
Can you point me to the right direction please? I have some knowledge of css and html but no really in php..especially when the code is mixed..

Many thank
dotcom22
Phoca Enthusiast
Phoca Enthusiast
Posts: 54
Joined: 10 Nov 2008, 18:19

Re: change entry display = edition of default.php

Post by dotcom22 »

great in fact I found it...is very simple...just need to add this:

at line 113:

$msgpg .= '<strong>';

at line 165:

$msgpg .= '</strong>';
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48726
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: change entry display = edition of default.php

Post by Jan »

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