//=====================================================
// enable alternative stylesheets only with JS
//=====================================================

//window.onload = function(e) {
//	var d = document.getElementById('wf-fontsize');
//	d.innerHTML = '<h2 title="Schriftgröße anpassen (erfordert Cookies)">TEXT</h2><ul><li id="wf-fontbigger"><a href="#" onclick="changeStylesheet(\'bigger\'); return false;" title="Schrift größer stellen">größer</a></li><li id="wf-fontsmaller"><a href="#" onclick="changeStylesheet(\'smaller\'); return false;" title="Schrift kleiner stellen">kleiner</a></li></ul>';
//}

//=====================================================
// clears an input box if Input.value == checkValue
//=====================================================

function clearInput( Input, checkValue ) {
	if ( Input.value == checkValue )
		Input.value = '';
}

//=====================================================
// reverts an input box if Input.value == ''
//=====================================================

function revertInput( Input, checkValue ) {
	if ( Input.value == '' )
		Input.value = checkValue;
}

//=====================================================
// toogles image of businesscard
// el          ... element
// firstFile  ... first filename
// secondFile ... second filename
//=====================================================

function toggleImg( el, firstFile, secondFile ) {
	if ( el.className == 'largeCard' ) {
		el.setAttribute('src', secondFile);
		el.className = 'smallCard';
	} else {
		el.setAttribute('src', firstFile);
		el.className = 'largeCard';
	}
}

//=====================================================
// opens url (to avoid duplicate links for newsitems)
// url        ... url
//=====================================================

function openUrl( url ) {
	window.location.href = url;
}

