/**
 * @author Csaba
 */

$(document).ready(function(){
	$.ajax({
		type: "GET",
		url: "images/pics.xml",
		dataType: "xml",
		success: function(xml) {
			
			$(xml).find('pic').each(function(){
				var picName = $(this).attr('name');
				//myPics.push(picName);
				$('#s1').append('<img src="images/'+picName+'">');
			});
			
			
			
			$('#s1').cycle({ 
			    fx:    'fade', 
			    random:  1,
			    timeout:  7000,
			    delay:  7000 
			});
		}
	});
	
	$("#s1").hide();
	setTimeout(function() {$("#s1").fadeIn("slow")}, 10000);
});


