вот шаблон table, в шапке темы описано как добавлять шаблоны
[spoiler title="table.php"]<?php
// no direct access
defined('_JEXEC') or die('Restricted access');
if ( ! defined('VMCategoriesTableDecoratorDefined') )
{
function VMCategoriesTableDecorator(&$node, &$args)
{
$categories = & VMCategories::getInstance();
$active = $categories->getActive();
$path = $active ? $active->getPath() : false;
$columns = 3;
$count = 0;
switch ($node->name())
{
case 'ul':
// get children before appending table
$children = $node->children();
// append table
$table = $node->addChild('table');
// iterate through list items
foreach ($children as $child)
{
// new table row if nesessary
if ($count % $columns == 0) {
$tr = $table->addChild('tr');
}
// append cell
$td = $tr->addChild('td');
// set current class
if ($path && $child->attributes('id') == $path[0]) {
$td->addAttribute('class', $td->attributes('class').' current');
}
// set active class
if ($path && in_array($child->attributes('id'), $path)) {
$td->addAttribute('class', $td->attributes('class').' active');
}
// append anchor
$a = $td->addChild('a');
$a->setData($child->a[0]->data());
$a->addAttribute('href', $child->a[0]->attributes('href'));
$count ++;
}
break;
case 'li':
break;
case 'a':
// do nothing
break;
}
// remove XML attributes
$node->removeAttribute('id');
$node->removeAttribute('level');
}
define('VMCategoriesTableDecoratorDefined', true);
}
// get XML directly coz we have to make some manipulations with it
$xml = & modVMCategoriesHelper::getXML($params);
if ($xml) {
// pass each node to $decorator function
$xml->map('VMCategoriesTableDecorator', array('xml'=>$xml, 'params'=>$params));
// just make table as root of xml
$xml = $xml->table[0];
$class_sfx = $params->get('class_sfx');
$tag_id = $params->get('tag_id');
$xml->addAttribute('class', 'menu'.$class_sfx);
$tag_id and $xml->addAttribute('id', $tag_id);
echo JFilterOutput::ampReplace( $xml->toString(true) );
}
[/spoiler]