Hi,
I had the same problem. I have modified the categoryTree function in mod_phocagallery_tree.php file so that the names longer than 15 characters are cut. The code searches the first space in the text, cuts the rest and then padds it with three dots:
// Categories tree
$tree = array();
$text = '';
$tree = categoryTree( $categories, $tree, 0, $text, $treeId );
// Create category tree
function categoryTree( $data, $tree, $id=0, $text='', $treeId ) {
foreach ( $data as $value ) {
if ($value->parentid == $id) {
$link = getLink($value->id);
$title = $value->text;
// Cut a long name.
if(strlen($title) > 15) {
$subtitle = explode(" ", $title);
$title = $subtitle[0] . ' ...';
}
$title = addslashes($title);
$showText = $text . ''.$treeId.'.add('.$value->id.','.$value->parentid.',\''.$title.'\',\''.$link.'\');'."\n";
$tree[$value->id] = $showText;
$tree = categoryTree($data, $tree, $value->id, '', $treeId);
}
}
return($tree);
}
You may see the effect here:
http://www.zlotniki.szkola.pl (on the right there is a module 'W galerii...').
However, it would be fine to see a full name when the mouse pointer is over the "shortened" title - maybe in a tooltip? The 'title' part of a 'href' tag would be OK, but where to put it? Have you any suggestions?
Best regards,
Stan