function updateForecastWidget(woeid) {
	$.cookie('WEATHER_STATION', woeid, {expires: 14, path: '/'});
	$('#weather_ajaxReplace').load('/weather/ajax/' + woeid);
}

$(document).ready(function(){
	
	$('#weatherExtrasLink').live('click', function() {
	  $('#weatherExtras').slideToggle("fast");
	});
	
	$('#extrasClose').live('click',function(event) {
		event.preventDefault();
		$('#weatherExtras').slideToggle("fast");
	});
	
	$('#forecastCity').live('change',function() {
		woeid = $('#forecastCity option:selected').attr('value');
		updateForecastWidget(woeid);
		$('#weatherExtras').slideToggle("fast");
	});
	
});


