[TYPO3-templavoila] Controlloing the layout of TemplaVoila

Tapio Markula tapio.markula at atwebteam.com
Sat Apr 21 09:16:33 CEST 2007


Hi

The most annoying feature thinking about skinning the
page module of TemplaVoila is that it creates page information
and content information using nested tables, which has the same
properties.

That make skinning really hard. It would be helpfull at least
defining different classes for the outhermost table.
That can be done adding a new parameter and in the first call,
lets call it '$page' and if the value is '1' that concerns the 
outhermost table.

1) first function call

			// Display the content as outline or the nested page structure:
		if ($BE_USER->isAdmin() && $this->MOD_SETTINGS['showOutline'])	{
			$output.= $this->render_outline($contentTreeData['tree']);
		} else {
			$output.= $this->render_framework_allSheets($contentTreeData['tree'], 
$this->currentLanguageKey,$array,$array,1); // here '1'

2) Function definition
function render_framework_allSheets($contentTreeArr, $languageKey='DEF', 
$parentPointer=array(), $parentDsMeta=array(),$page=0) {

...

$this->render_framework_singleSheet($contentTreeArr, $languageKey, 
'sDEF', $parentPointer, $parentDsMeta,$page);

3) Generating tables - add new class for the outhermost table


if($page) {
	$typo3_page_ceHeader=' typo3-page-ceHeaderPage';
	}
else $typo3_page_ceHeader=' typo3-page-ceHeaderContent';

<table cellpadding="0" cellspacing="0" 
class="typo3-page-ceHeader'.$typo3_page_ceHeader.'">';


NOW you can easily at least create different borders for the outhermost 
table and content elements - and define them freely.

.typo3-page-ceHeaderPage { border:...}
.typo3-page-ceHeaderContent { border: }

That small change make skinning remarkable easier!


More information about the TYPO3-project-templavoila mailing list