//Gets the news source for the blog
function GetBlogPosts(num)
{
//Looping vars
var iPost = num;
var maxPosts = blogPosts.length;
var currentPost = blogPosts[iPost]
//post information
var title = currentPost[0];
var url = currentPost[1];
var publishedDate = currentPost[2];
var desc = currentPost[3];
//Set the published Date
var dateStamp = document.getElementById("dateStamp");
dateStamp.innerHTML = publishedDate
//Set the title
var blogHeadline = document.getElementById("blogHeadline");
blogHeadline.innerHTML = "" + title + " * " + desc + "";
//Go to the next post
iPost += 1
//If we're at the last, reset the loop
if(iPost == maxPosts)
{
iPost = 0
}
//Callback to start the function again
window.setTimeout("GetBlogPosts(" + iPost + ")", 3000);
}