leider klappt sich meine Navigation nicht mehr aus und ich weiß nicht, warum:
Wüsste nicht, was ich daran geändert habe. Jedenfalls werden nur noch Hauptebenen ausgegeben. Die gewählte Kategorie wird mit der active-Klasse versehen. Also eigentlich alles richtig, nur eben nicht die (auf online gestellten) Kategorien :/<?php
// EXPLODE PATH
$PATH = explode("|",$this->getValue("path").$this->getValue("article_id")."|");
// GET CURRENTS
$path1 = $PATH[1];
$path2 = $PATH[2];
$path3 = $PATH[3];
$path4 = $PATH[4];
$path5 = $PATH[5];
/* START 1st level categories */
$navHeader .= "\r\n".'<ul id="Navigation">'."\r\n";
foreach (OOCategory::getRootCategories() as $lev1) {
if ($lev1->isOnline()):
if ($lev1->getId() == $path1) {
$navHeader .= '<li class="active"><a class="current" href="'.$lev1->getUrl().'">'.$lev1->getName().'</a></li><!--deep_nav-->'."\r\n";
if ($lev1->getId() != "1") {
$sitePath .= ' ›› <a href="'.$lev1->getUrl().'">'.$lev1->getName().'</a>';
}
$titlePath .= ' >> '.$lev1->getName();
}
// 2nd level - no active link
else {
$navHeader .= '<li><a href="'.$lev1->getUrl().'">'.$lev1->getName().'</a></li>'."\r\n";
}
// 1st level had categories? -> go on
$lev1Size = sizeof($lev1->getChildren());
$navLeftCol='';
if ($lev1->getId() == $path1) {
if ($lev1Size != "0"):
$navLeftCol .= "\r\n<li>\r\n".'<ul class="nav2nd">'."\r\n";
//$navLeftCol .= '<li><strong>Unterkategorien</strong></li>'."\r\n";
// START 2nd level categories
foreach ($lev1->getChildren() as $lev2):
if ($lev2->isOnline()):
// 2nd level - active link
if ($lev2->getId() == $path2) {
$navLeftCol .= '<li class="active"><a class="current" href="'.$lev2->getUrl().'">'.$lev2->getName().'</a>';
$sitePath .= ' ›› <a href="'.$lev2->getUrl().'">'.$lev2->getName().'</a>';
$titlePath .= ' >> '.$lev2->getName();
}
// 2nd level - no active link
else {
$navLeftCol .= '<li><a href="'.$lev2->getUrl().'">'.$lev2->getName().'</a></li>'."\r\n";
}
// 2st level had categories? -> go on
$lev2Size = sizeof($lev2->getChildren());
if ($lev2->getId() == $path2) {
if ($lev2Size != "0"):
$navLeftCol .= '<ul class="nav3rd">'."\r\n";
//$navLeftCol .= '<li><strong>Unterkategorien2</strong></li>'."\r\n";
// START 3nd level categories
foreach ($lev2->getChildren() as $lev3):
if ($lev3->isOnline()):
// 3nd level - active link
if ($lev3->getId() == $path3) {
$navLeftCol .= '<li class="active"><a class="current" href="'.$lev3->getUrl().'"><img src="../pics/nav_punkt.gif" alt="nav_icon" style="vertical-align:middle" />'.$lev3->getName().'</a>';
$sitePath .= ' ›› <a href="'.$lev3->getUrl().'">'.$lev3->getName().'</a>';
$titlePath .= ' >> '.$lev3->getName();
}
// 3nd level - no active link
else {
$navLeftCol .= '<li><a href="'.$lev3->getUrl().'"><img src="../pics/nav_punkt_leer.gif" alt="nav_icon" style="vertical-align:middle" />'.$lev3->getName().'</a>';
}
endif;
$navLeftCol .= '</li>'."\r\n";
endforeach;
$navLeftCol .= '</ul>'."\r\n";
// END 3nd level categories
endif;
$navLeftCol .= '</li>'."\r\n";
}
// END 2nd level categories
endif; // END by if ($lev1Size != "0"):
endforeach;
//$navHeader .= '</li>'."\r\n";
endif;
if ($navLeftCol != "") $navLeftCol .= '</ul>'."\r\n</li>\r\n";
}
endif; // END by if ($lev1->isOnline())
}
$navHeader .= '</ul>'."\r\n";
// END 1st level categories
if ($REX['CUR_CLANG'] == 1) $breadcrumb = 'You are here: <a href="/index.php?clang=1">Startpage</a> '.$sitePath;
else $breadcrumb = 'Sie sind hier: <a href="/index.php">Startseite</a> '.$sitePath;
?>
Bitte um Hilfe.
Danke