var Weather = {

	base : 'module/system/widget/weather/',

	init : function(){
		Weather.get();
	},

	get : function(){
		Mo.json( Weather.base + "json.php?callback=?", {}, function( data ){ Weather.write( data ); } );
	},

	write : function( data ){
		Mo('#weather').html('<img src="'+ data.icon +'" />'+data.condition+'<br />'+data.humidity+'<br />'+data.wind_condition);
	}

}

Weather.init();
