diff --git a/include/shared-manual.inc b/include/shared-manual.inc
index 2969f35a0..c8e7b2685 100644
--- a/include/shared-manual.inc
+++ b/include/shared-manual.inc
@@ -49,7 +49,7 @@ function makeBullet($url,$number,$offtype,$offnum) {
function makeBorderTOC($this)
{
- global $NEXT, $PREV, $UP, $HOME, $TOC, $FONTFACEATTR, $PHP_SELF;
+ global $NEXT, $PREV, $UP, $HOME, $TOC, $FONTFACEATTR, $PHP_SELF, $DOCUMENT_ROOT;
global $HAVE_STYLE, $HAVE_TD_BG;
$tocfontsize = "-1"; // replace with CSS?
@@ -66,13 +66,14 @@ function makeBorderTOC($this)
echo "$UP[1]\n";
$this = eregi_replace("^Manual: *", "", $this);
+ $cur = substr(dirname($PHP_SELF),-3);
$file = basename($PHP_SELF);
if(substr($file,-5)=='.php3') $file = substr($file,0,-1);
- echo "
";
- echo "
";
- echo "
";
- echo "
";
- echo "
";
+ if($cur!='ual') echo "
";
+ if($cur!='/de' && is_file("$DOCUMENT_ROOT/manual/de/$file")) echo "
";
+ if($cur!='/ja' && is_file("$DOCUMENT_ROOT/manual/ja/$file")) echo "
";
+ if($cur!='/it' && is_file("$DOCUMENT_ROOT/manual/it/$file")) echo "
";
+ if($cur!='/fr' && is_file("$DOCUMENT_ROOT/manual/fr/$file")) echo "
";
for ($i = 0; $i < count($TOC); $i++) {
list($url, $title) = $TOC[$i];