ich verwende das Standard-Modul "Navigation_Breadcrumb" doch leider gibt diese die Links nicht mit der "lang" aus sondern nur idcat. Wie bekomme ich es hin, das auch die Sprache mit ausgegeben wird?
Code: Alles auswählen
<?php
/**
* $RCSfile$
*
* Description: Build a breadcrumb navigation
* starting from top idcat (of given level) down to current idcat
*
* @version 1.0.0
* @author Rudi Bieller
* @copyright four for business AG <www.4fb.de>
*
* {@internal
* created 2008-04-08
* }}
*
* $Id$
*/
// include Contenido_FrontendNavigation_Breadcrumb class
cInclude('classes', 'Contenido_FrontendNavigation/Contenido_FrontendNavigation_Breadcrumb.class.php');
try {
$oBreadcrumb = new Contenido_FrontendNavigation_Breadcrumb($db, $cfg, $client, $lang, $cfgClient);
$oBreadCategories = $oBreadcrumb->get($idcat, 0); // starting level in this case is 1, not 0
if ($oBreadCategories->count() > 0) {
foreach ($oBreadCategories as $oBreadCategory) {
// please remember, this is a sample - or a live application it's better to use a template!
echo '> <a href="front_content.php?idcat='.$oBreadCategory->getIdCat().'">'.
$oBreadCategory->getCategoryLanguage()->getName().
'</a> ';
}
}
} catch(Exception $e) {
echo 'Shit happens: ' . $e->getMessage() . ': ' . $e->getFile() . ' at line '.$e->getLine() . ' ('.$e->getTraceAsString().')';
}
?>