function brwstester()
{
    return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body;
}

function resizeheights(me)
{
    $("#" + me).css({'height' : $(window).height() + brwstester().scrollTop  + "px"});
}
function ScrollEvent(Div)
{
	$(window).scroll(function()
     {
         resizeheights(Div);
     });
}

function ShowArticleParticipation()
{
	document.location='#';
	
	$("#ArticleBackground").css({
			"opacity": "0.7"
	});
	$("#ArticleBackground").fadeIn("slow");
	$("#Article").fadeIn("slow");

	var windowWidth = document.documentElement.clientWidth;
	var windowHeight = document.documentElement.clientHeight;
	var popupHeight = $("#Article").height();
	var popupWidth = $("#Article").width();
	//centering

	$("#Article").css({
		"position": "absolute",
		"top": "10%",
		"left": windowWidth/2-popupWidth/2,
		"height":"100%"
	});

	//only need force for IE6
	$("#ArticleBackground").css({
		"height": windowHeight
	});
	ScrollEvent('ArticleBackground');
}
function CloseArticleSubscription()
{
	$("#ArticleBackground").fadeOut("slow");
	$("#Article").fadeOut("slow");
	
}
function ShowTellFriend()
{
	//document.location='#tellfriend';
	
	$("#tellfriend").fadeIn("slow");
}
function CloseTellFriend()
{
	$("#tellfriend").fadeOut("slow");
}
