aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorplegall <plg@piwigo.org>2005-11-18 22:45:16 +0000
committerplegall <plg@piwigo.org>2005-11-18 22:45:16 +0000
commit1ba53a2ffa47e9e6c860b5d3d285b4d22245e815 (patch)
tree8ccfe5dc320c9bb8c765a0f3ae5654f39479e0fc /include
parent7f69573936644604e9249148cf1136b592f5a7bd (diff)
- merge -r939:940 from branch-1_5 (bug fixed in HTML for category menu tree)
git-svn-id: http://piwigo.org/svn/trunk@941 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--include/functions_html.inc.php23
1 files changed, 8 insertions, 15 deletions
diff --git a/include/functions_html.inc.php b/include/functions_html.inc.php
index 5fe88fb63..bfd3957ff 100644
--- a/include/functions_html.inc.php
+++ b/include/functions_html.inc.php
@@ -346,25 +346,21 @@ function get_html_menu_category($categories)
$level = substr_count($category['global_rank'], '.') + 1;
if ($level > $ref_level)
{
- $menu.= '
- <ul>';
+ $menu.= "\n<ul>";
}
else if ($level == $ref_level)
{
- $menu.= '
- </li>';
+ $menu.= "\n</li>";
}
else if ($level < $ref_level)
{
// we may have to close more than one level at the same time...
- $menu.= str_repeat("\n</ul>",($ref_level-$level));
$menu.= "\n</li>";
+ $menu.= str_repeat("\n</ul></li>",($ref_level-$level));
}
$ref_level = $level;
- $menu.= '
-
- <li';
+ $menu.= "\n\n".'<li';
if (isset($page['cat'])
and is_numeric($page['cat'])
and $category['id'] == $page['cat'])
@@ -374,13 +370,11 @@ function get_html_menu_category($categories)
$menu.= '>';
$url = add_session_id(PHPWG_ROOT_PATH.'category.php?cat='.$category['id']);
- $menu.= '
- <a href="'.$url.'">'.$category['name'].'</a>';
+ $menu.= "\n".'<a href="'.$url.'">'.$category['name'].'</a>';
if ($category['nb_images'] > 0)
{
- $menu.= '
- <span class="menuInfoCat"';
+ $menu.= "\n".'<span class="menuInfoCat"';
$menu.= ' title="'.$category['nb_images'];
$menu.= ' '.$lang['images_available'].'">';
$menu.= '['.$category['nb_images'].']';
@@ -388,9 +382,8 @@ function get_html_menu_category($categories)
$menu.= get_icon($category['date_last']);
}
}
-
- $menu.= '</li>
- </ul>';
+
+ $menu.= str_repeat("\n</li></ul>",($level));
return $menu;
}