function selectFach(theSelect)
{
	if (theSelect.options[theSelect.selectedIndex].value)
	{
		window.location.href = '/reihen/reihen.asp?f=' + theSelect.options[theSelect.selectedIndex].value;
	}
}

function popup(url, width, height)
{
	var win = open(url, 'popup', 'width=' + width + ', height=' + height + ', locationbar=no, menubar=yes, resizable=no, status=no, scrollbars=yes');
	win.focus ();
	if (win.opener == null) win.opener = self;
	win.focus();
}

window.addEvent('domready', function() 
{
	$(document.body).getElements('a.header').addEvents({
	    'click': function(){
	        if (this.getParent().getElement('ul').isDisplayed())
			{
				this.getParent().swapClass('minus', 'plus');
			}
			else
			{
				this.getParent().swapClass('plus', 'minus');
			}
			this.getParent().getElement('ul').get('reveal').toggle();
			return false;
	    }
	});
	
	$('schnellsuche').addEvents({
		'click': function(){
			if ($('schnellsuche').value == 'Stichwort / Titelnummer / ISBN')
			{
				$('schnellsuche').value = '';
				$('schnellsuche').style.color = 'black';
			}
		},
		'blur': function(){
			if (!$('schnellsuche').value)
			{
				$('schnellsuche').value = 'Stichwort / Titelnummer / ISBN';
				$('schnellsuche').style.color = '#777';
			}
		}
	});
});