Hiya Everyone,

My Page: Untitled Document

Click on what are going to be buttons, the blue ones at the bottom. You'll see my curtains close. From here I wish for the content to switch and then the curtains re-open straight after.

Code:
var PreviousLocation;
var CurrentLocation;
$("#Home .button").click(function () {
	var slidedown = '#' + $(this).attr('id').replace('_Btn', '');
		PreviousLocation = '#' + $(this).parent().parent().attr('id');
		CurrentLocation = '#' + $(this).attr('id').replace('_Btn', '');
		DomainPush = $(this).attr('id').replace('_Btn', '');
	$(".CurtainsLeft").show("slide", { direction: "left" }, 1000);
	$(".CurtainsRight").show("slide", { direction: "right" }, 1000);
	//$("#Home").slideUp(2000);
	//$(slidedown).slideDown(2000);
	//history.pushState(null, null, "?Category=" + DomainPush);

});

$("#Fundraiser_Categories .button").click(function () {
	var slidedown = '#' + $(this).attr('id').replace('_Btn', '_Fundraising_Content');
	PreviousLocation = '#' + $(this).parent().parent().attr('id');
	CurrentLocation = '#' + $(this).attr('id').replace('_Btn', '_Fundraising_Content');
	DomainPush = $(this).attr('id').replace('_Btn', '_Fundraising');
	$("#Fundraiser_Categories").slideUp(2000);
	$(slidedown).slideDown(2000);
	history.pushState(null, null, "?Category=fundraising&content=" + DomainPush);
});
I am also having the problem of returning my two variables "PreviousLocation" and "CurrentLocation" to be used on my on pop state when navigate backwards to not show the previous content as the last. See what I mean by clicking the largest button then navigating back, however this does not occure if you click the largest button, then another and navigate back. Only when you navigate back to the #Main

Best Regards,
Tim