function getNews(){
var output = $("#news_01");
var sourceXml = "/pprb/pr_rss_sc.xml";
$.ajax({
	type: "GET",
    url: sourceXml,
    dataType: "xml",
    success: function(xml){
		$(output).html('');
		var newsCounter = 0;
		$(xml).find("item:lt(3)").each(function(){			
			$(output).append('<div style="color:#650000;">- <a href="#" onclick="javascript: showNews('+newsCounter+');" style="font-size:13px;">'
				+$(this).find("title").text() + " (" + $(this).find("pubDate").text()
				+")</a></div>");	
		$("#hiddenDiv").append('<div id="'+newsCounter+'">' + $(this).find("description").text() + '</div>');
			newsCounter += 1;
		});		
	}
})
}

function showNews(counter) {
	$('#dialogDiv').html($("#hiddenDiv div[id=" + parseInt(counter)+"]").html());
	$('#dialogDiv').dialog({ autoOpen: false });
	$('#dialogDiv').dialog('option', 'title', 'Press Release');
	$('#dialogDiv').dialog('open');
}

              function rollMPImage(){
                var container = $("#output");
                var mpurl = "06_appeals_public/missing/person.xml";
                var arr;
                var i = 0;
                var pause = 10000;

                $.ajax({
                    type: "GET",
                    url: mpurl,
                    dataType: "xml",
                    success: parseXml
                })


                function rollImage(i){
                    i += 1;
                    if(i >= arr.length){i = 0;}
					container.html("<img width='71' height='91' border='0'  src='" + $(arr[i]).text()+"'/>");
					//container.hide();
                    //container.slideDown("slow");
					setTimeout(function(){rollImage(i)}, pause);
                }

                function parseXml(xml){
                    arr = jQuery.makeArray($(xml).find("img"));
                    container.html("<img width='71' height='91' border='0' src='" + $(arr[i]).text()+"'/>");
                    setTimeout(function(){rollImage(i)}, pause);
                }            
            }

