

jQuery(document).ready(function() {
	
	jQuery('.art_thumb').click(function() {
		  
		  my_class = jQuery(this).attr('class');  
		
		  new_src = jQuery(this).attr('src');
		  par1 = jQuery(this).parent();
		  jack = jQuery(par1).find('.art_main');
		  mack = jQuery(par1).find('.first'); 
		  old_src = jQuery(jack).attr('src');
		  
		  jQuery(jack).attr('src',new_src);
		  
		  if(my_class.search(/no_href/i)==-1)
			  jQuery(mack).attr('href',new_src.replace('200,200','800,600'));
		  
		  jQuery(this).attr('src',old_src);
		  
		  		  
	});
	
	 
	
	jQuery('input[title!=""]').hint();
	
	jQuery("a.article").fancybox(
			{
				'easingIn'				: 'easeOutBack',
				'easingOut'				: 'easeInBack',
				'hideOnContentClick'	: false

			}
	);
	
	jQuery(function() {
		jQuery("#tree").treeview({
			collapsed: true,
			animated: "medium",
			control:"#sidetreecontrol"			
		});
	});
	
	jQuery("a#printlink").click(function(){
	    jQuery("div.content").printArea();
	});
	jQuery(".main").height(function(){
		var wHeight = jQuery(window).height();
		var mainDivHeight = jQuery(".main").height();
		var topBarHeight = jQuery(".top_bar").height();
		if (wHeight > mainDivHeight)
			return wHeight-topBarHeight-35;
		else
			return mainDivHeight;
	});

});




	

