function callMouseIn () {
	jQuery('#phone_hover').show();
	
	if (jQuery.browser['msie'] == true &&
		jQuery.browser['version'] == 6.0) {
	jQuery('body').css('background-position', '0px 75px');
	}
}
function callMouseOut () {
	jQuery('#phone_hover').hide();
	if (jQuery.browser['msie'] == true &&
		jQuery.browser['version'] == 6.0) {
		jQuery('body').css('background-position', '0px 0px');
	}
}

function frmcheck(obj,state,text) {
	
	if(obj.value=="" && state==0)
		obj.value = text;
	else if(obj.value==text && state==1)
		obj.value = "";

}

function fonback() {
	
	if (typeof(fon_send) != "undefined") {
		jQuery('#call_message').html('Ihre Mitteilung wurde bereits einmal versendet.');
		return false;
	}

	if (jQuery('#call_firma').attr('value') == "Firma") {
		jQuery('#call_firma').css('background-color', '#FFAAAA');
		jQuery('#call_message').html('Bitte prüfen Sie ihre Eingaben.');
		return false;
	} else {
		jQuery('#call_firma').css('background-color', '#FFFFFF');
	}	
	
	if (jQuery('#fon').attr('value') == "Ihre Tel. Nr.") {
		jQuery('#fon').css('background-color', '#FFAAAA');
		jQuery('#call_message').html('Bitte prüfen Sie ihre Eingaben.');
		return false;
	} else {
		jQuery('#fon').css('background-color', '#FFFFFF');
	}	
	
	if (jQuery('#call_name').attr('value') == "Ihr Name") {
		jQuery('#call_name').css('background-color', '#FFAAAA');
		jQuery('#call_message').html('Bitte prüfen Sie ihre Eingaben.');
		return false;
	} else {
		jQuery('#call_name').css('background-color', '#FFFFFF');
	}
	
	postArray = {
		name: jQuery('#call_name').attr('value'),
		fon: jQuery('#fon').attr('value'),
		firma: jQuery('#call_firma').attr('value'),
	}

	jQuery.post("/fileadmin/templates/callback.php",
		postArray,
		function(data){
			if (data == "1") {
				jQuery('#call_message').html('Ihre Mitteilung wurde versendet.');
				fon_send = true;
				jQuery('#fonbutton').hide();
			} else {
				jQuery('#call_message').html('Bitte prüfen Sie nochmal Ihre Eingaben.');
			}
		});
}
