

	var url_uebergabe=location.search;
	url_uebergabe=url_uebergabe.substring(1, url_uebergabe.length);
	escape(url_uebergabe);



$(document).ready(function() {

$("a[rel='webcams']").colorbox();
$("a[rel='lightbox']").colorbox();

});
	
function aktWetter() {

// hier manuelle tendenz einlesen...
//	new Ajax.Request('/aktuell/tendenz.txt', {asynchronous:true,method:'GET', onSuccess:function(t){ if (t.responseText) {tendenz = t.responseText; } }, onFailure:errFunc });


$(document).ready(function() {

$("a[rel='webcams']").colorbox();
$("a[rel='lightbox']").colorbox();

	$('#wetterloading').html('<br/>Livedaten werden geladen...<br/><br/><img src="/images/ajax-loader.gif">');

	$.ajax({
		  type: "GET",
		  url: "/aktuell/wswindata.xml",
			dataType: "xml",
		  success: function(xml){
			
			$(xml).find('WXDATA').each(function(){
				
												$('#wetterloading').hide();
												$('#wetterdaten').show();
                        
                        var tempAktuell = $(this).find('curval0').text();
												var windGrafik = $(this).find('windd_gra').text();
												var windrichtungAktuell = $(this).find('wind_txtlong').text();
												var windA = $(this).find('curval_35_').text();
                         
                        var baroGrafik = '<img src="http://www.upland-wetter.de/images/wettersymbole/' + $(this).find('ws_baro_icon').text() + '" align="left" vspace="2" hspace="2">'; 
                        
                        
                        var tempAktuell= $(this).find('curval0').text().split(',');

													tempAktuell[0]=tempAktuell[0].substring(1,3);
													
													if ( tempAktuell[0] <= 60 ) {
														$('#tempAktuell').html( $(this).find('curval0').text() );	
														//durchschnitt + '/<span class="wetterData10px"> &Oslash; ' + $(this).find('avgval0').text() + '</span>
													} else {
														$('#tempAktuell').html('--');
													}

													$('#baro_station').html( baroGrafik + $(this).find('luftdruck').text() + '/' + $(this).find('curval-1').text() + '<br>' + $(this).find('ws_barotendencytxt').text() );
													$('#forcastAktuell').html( $(this).find('forecast_txt').text());	
													$('#windAktuell').html('<img src="http://www.upland-wetter.de/images/wettersymbole/' + windGrafik + '" align="left" vspace="2" hspace="2">' + windrichtungAktuell + '<br/>' + windA );
													$('#wettertime').html( $(this).find('ws_time').text() + '/'  + $(this).find('ws_date').text() );	

                     });
				
		  },

		  error: function(msg){
			$("#wetterloading").html('Ups, Momentan sind keine Daten vorhanden...');
		  }
});





if ( $("#vorhersage_hessen").height() < 30 ) {
	//alert($("#vorhersage_hessen").height());
	$("#vorhersage_hessen").html("Momentan sind keine Daten vorhanden...");
}	

if ( $("#vorhersage_germany").height() < 30 ) {
	$("#vorhersage_germany").html("Momentan sind keine Daten vorhanden...");
}	

});

}

