var $j = jQuery.noConflict();
$j(document).ready(function() {
	$j("#content_topnav").find('div > ul > li').hover(function () {
		// Mouseover
		$j(this).find('ul').css({
			'height': 0,
			'min-height': 0,
			'overflow': 'hidden'
		});
		$j(this).find('ul').stop().animate({ 
			'height': '170px'
		}, 'fast');
		// Mouseout
		}, function () {
			$j(this).find('ul').stop().animate({
				'height': 0
		}, 'fast');
	});
	
	$j(".metanav_ul").find('> li').hover(function () {
		// Mouseover
		$j(this).find('ul').css({
			'height': 0,
			'min-height': 0,
			'overflow': 'hidden'
		});
		$j(this).find('ul').stop().animate({ 
			'height': '160px'
		}, 'fast');
		// Mouseout
		}, function () {
			$j(this).find('ul').stop().animate({
				'height': 0
		}, 'fast');
	});

	$j('a[href$=".pdf"]').each(function(i) {
		// Überflüssige Chars am Anfang der URL entfernen
		var theSource = $j(this).attr('href');
		var trashUrlChars = theSource.indexOf("Webmaster");
		var theCleanSource = theSource.substr(trashUrlChars + 10);
		
		// Attribut mit Attributwerten setzen
		// $j(this).attr('onClick', 'javascript:pageTracker._trackPageview("' + theCleanSource + '");'); // für synchron
		$j(this).attr('onClick', "javascript:_gaq.push(['_trackPageview', '" + theCleanSource + "']);"); // für asynchron
	});
});
