window.onload = function() {
}
//----------------------------------------------------
function ReversePosts() {
    var postsList = new Array();
	var placeHolder = new Element("div");
	$$('.post').each(function(el) { postsList.push(el);  }); // Get a list of all posts
	if (postsList.length < 2) { return false; } // If there aren't at least 2, nothing to reverse
	postsList[0].insert({ "before" : placeHolder }); // Insert a placeholder, to have a handle where to reinsert posts
	postsList.each(function(el){ el.remove(); }); // Remove all posts
	postsList.reverse();
	postsList.each(function(el){ placeHolder.insert({ "before" : el }); }); // Reinsert all posts, relative to the placeholder
	placeHolder.remove();
	return false;
}
//----------------------------------------------------
function NextPost(el) {
	//try {
		var nextPost = $(el).up(".post").next(".post");
		if (!nextPost) { window.scrollTo(0,99999999); return false; }
		nextPost.down("h2").scrollTo();
		return false;
	//} catch(e) {}
}
//----------------------------------------------------
