$(document).ready(function(){
	$("#quicklinks").change(function(){
		document.location = $(this).find("option:selected").val();
	});
	
	$("#footer .centeredfooter .quicknav>ul>li:odd").width(250).css('marginRight',0);
	
	$('.newsletter_signup_click a').openDOMWindow({ 
		eventType:'click',
		height:250,
		width:220
	}); 
	
	$('ul.staff li a').openDOMWindow({
		eventType:'click',
		loader:1, 
		loaderImagePath:'/wp-content/themes/tlg/images/ajax-loader.gif', 
		loaderHeight:16, 
		loaderWidth:16, 
		windowSource:'ajax', 
		windowHTTPType:'post' 
	});
	
	$('p.links .readmore a').openDOMWindow({
		eventType:'click',
		loader:1, 
		loaderImagePath:'/wp-content/themes/tlg/images/ajax-loader.gif', 
		loaderHeight:16, 
		loaderWidth:16, 
		windowSource:'ajax',
		windowHTTPType:'post' 
	});
	
	/*$("#container .readmore a").click(function(){
		if($($(this).attr('rel')+":visible").length>0) $(this).html("Read More &gt;&gt;");
		else $(this).html("Read Less &gt;&gt;");
		$($(this).attr('rel')).slideToggle();							   
	});*/
	
	$("#access ul.menu li").hover(function(){
		$(this).find("ul").slideDown(100);
	},function(){
		$(this).find("ul").slideUp(100);
	});
	
	var basesize= parseInt($("body .post").css("font-size"));
	
	$(".fontbigger").click(function(){
		basesize++;
		if(basesize>16){
			basesize=16;
		}else{
			$("#content *").each(function(){
				$(this).css("font-size",(parseInt($(this).css("font-size"))+1)+"px");
				$(this).css("line-height",(parseInt($(this).css("line-height"))+1)+"px");
			});
		}
	});
	$(".fontsmaller").click(function(){
		basesize--;
		if(basesize<11){
			basesize=11;
		}else{
			$("#content *").each(function(){
				$(this).css("font-size",(parseInt($(this).css("font-size"))-1)+"px");
				$(this).css("line-height",(parseInt($(this).css("line-height"))-1)+"px");
			});
		}
	});
});
