//simple breadcrumb
function breadcrumb() {
	var actURL,ieURL,fileName,file,ieFile,a,liID,aAhref,afCdat,aP,aPAhref,aPfCdat,t0,t1,t2,t3,t4,t5,fileIntern,aFunc,iColor;
	t0 = '[ <strong title="Sie befinden sich auf der Seite: ';t1 = '</a> ] - ' + t0;t2 = '</strong> ]';t3 = '" title="zur&uuml;ck auf die Seite: ';t4 = '[ <a href="';t5 = '">';
	actURL = window.location.pathname;
	fileName = actURL.slice(actURL.lastIndexOf('/')+1, actURL.lastIndexOf('.html'));
	fileIntern = actURL.search('/intern/');
	file = fileName + '.html'
	a = $('navi').getElementsByTagName('a');
	aFunc = $('funcNav').getElementsByTagName('a');
	if (fileIntern == -1){
		//single public pages
		if(file == 'impressum.html'){$('breadcrumb').innerHTML = t0 + 'Impressum &amp; Rechtliches">Impressum &amp; Rechtliches' + t2;}
		if(file == 'sitemap.html'){$('breadcrumb').innerHTML = t0 + 'Sitemap">Sitemap' + t2;}
		if(file == 'archiv.html'){$('breadcrumb').innerHTML = t4 + 'aktuelles.html' + t3 + 'Aktuelles">Aktuelles' + t1 + 'Archiv">Archiv' + t2;}
		//full menue public pages
		for (var i = 0; i < a.length; i++)
		if (a[i].getAttribute('href') == file){
			a[i].style.fontWeight = 'bold';
			aAhref = a[i].getAttribute('href');
			afCdat = a[i].firstChild.data;
			liID = a[i].parentNode.getAttribute('id');
			aP = liID.slice(0,2);
			aPAhref = $(aP).firstChild.getAttribute('href');
			aPfCdat = $(aP).firstChild.firstChild.data;
			if(liID.length == 2){
				$('breadcrumb').innerHTML = t0 + afCdat + t5 + afCdat + t2;
			}else{
				$(aP).firstChild.style.fontWeight = 'bold';
				$('breadcrumb').innerHTML = t4 + aPAhref  + t3 + aPfCdat + t5 + aPfCdat + t1 + afCdat + t5 + afCdat + t2;
			}
		}else{
			ieURL = a[i].getAttribute('href');
			ieFile = ieURL.slice(ieURL.lastIndexOf('/')+1, ieURL.lastIndexOf('.html')) + '.html';
			aAhref = a[i].getAttribute('href');
			afCdat = a[i].firstChild.data;
			liID = a[i].parentNode.getAttribute('id');
			aP = liID.slice(0,2);
			aPAhref = $(aP).firstChild.getAttribute('href');
			aPfCdat = $(aP).firstChild.firstChild.data;
			if (ieFile == file){
				a[i].style.fontWeight = 'bold';
				if(liID.length == 2){
					$('breadcrumb').innerHTML = t0 + afCdat + t5 + afCdat + t2;
				}else{
					$(aP).firstChild.style.fontWeight = 'bold';
					$('breadcrumb').innerHTML = t4 + aPAhref + t3 + aPfCdat + t5 + aPfCdat + t1 + afCdat + t5 + afCdat + t2;
				}		
			}else{}
		}		
	}else{
		//internal pages
		if(file == 'index.html'){$('breadcrumb').innerHTML = t0 + 'GEB Intern: Start">GEB Intern: Start' + t2;}
		if(file == 'archiv2008.html'){$('breadcrumb').innerHTML = t0 + 'GEB Intern: Archiv 2008">GEB Intern: Archiv 2008' + t2;}
		if(file == 'Relaunch2009.html'){$('breadcrumb').innerHTML = t0 + 'GEB Intern: Website">GEB Intern: Website' + t2;}
		iColor = '#69f';
		$('mainNav').style.color = iColor;
		$('funcNav').style.color = iColor;		
		for (var i = 0; i < a.length; i++)
		a[i].style.color = iColor;
		for (var y = 0; y < aFunc.length; y++)
		aFunc[y].style.color = iColor;
	}
}
