site = function()
{
	$(document).ready(function()
		{
			site.toggleBlogComments();
			site.toggleHydeparkComments();
			site.setCBoxSize();
			var browser=navigator.appName;
			var b_version=navigator.appVersion;
			
			
			if (browser=="Microsoft Internet Explorer")
			{
				var IE6 = false /*@cc_on || @_jscript_version < 5.7 @*/;
				var version=parseFloat(b_version.substr(22));
				if (version < 7.0)
					window.location = '/public/update_browser.html';
			}
			
		}
	);
	
	
	this.toggleBlogComments = function()
	{
	$(".showCommentsSpan").click(function () {
      id = $(this).attr("id");
	  idNr = id.slice(5);
	  $("#comDiv"+idNr).toggle();
    });

	}
	
	this.toggleHydeparkComments = function()
	{
	$(".showHCommentsSpan").click(function () {
      id = $(this).attr("id");
	  idNr = id.slice(9);
	  $("#comDivHyd"+idNr).toggle();
    });

	}
	
	this.setCBoxSize = function()
	{
		h = $("#contentColumn").get(0);
		c = $("#centerColumnAll").get(0);
		
		//alert(c.clientHeight+" "+h.clientHeight);
		if (c.clientHeight < h.clientHeight)
			$("#centerColumnAll").css("height",h.clientHeight+80);

		if (c.clientHeight < 600)
			$("#centerColumnAll").css("height",600+30);
		
		
		setTimeout("site.setCBoxSize();", 3000);

	}
}
