
		


		
		


			function sIFR() {
		var fdetect = deconcept.SWFObjectUtil.getPlayerVersion();
		if (fdetect['major'] != 0) {
			$.sifr({
				path: '/images/skin/',
				save: true
			});
			$('.dosifr').sifr({ font: 'skinv1-font1', color: '#58A01F', fontSize:'24px' });
		}
	}	
	
	jQuery().ready(function() {

		$.ajaxSetup ({ cache: false });
		
		$('#sortable tr:odd, .sortable tr:odd').addClass('odd');
		$('#sortable tr:even, .sortable tr:even').addClass('even');

		$("div.profilev > img, div.profileh > img").wrap('<a class="fancy"></a>');
		$("div.profilev > a, div.profileh > a").each(
			function( intIndex ){
				$(this).attr('href', $(this).find('img').attr('src'));
			}
		);

		$("a.fancy").fancybox({
			'hideOnContentClick'	: false,
			'frameWidth'			: Math.min(860, $(window).width() - 60),
			'frameHeight'			: $(window).height() - 60,
			'overlayShow'			: true,
			'zoomSpeedIn'			: 600,
			'zoomSpeedOut'			: 500,
			'easingIn'				: 'easeOutBack',
			'easingOut'				: 'easeInBack'
		});  

		$("a.showcase").fancybox({
			'hideOnContentClick'	: false,
			'frameWidth'			: 660,
			'frameHeight'			: $(window).height() - 60,
			'overlayShow'			: false,
			'zoomSpeedIn'			: 600,
			'zoomSpeedOut'			: 500,
			'easingIn'				: 'easeOutBack',
			'easingOut'				: 'easeInBack',
			'centerOnScroll'		: false,
			'callbackOnClose'		: function() { $('#viewport').html(''); }
		}); 

		$("#events a, .calevent").fancybox({
			'hideOnContentClick'	: false,
			'frameWidth'			: 500,
			'frameHeight'			: 500,
			'overlayShow'			: false,
			'zoomSpeedIn'			: 600,
			'zoomSpeedOut'			: 500,
			'easingIn'				: 'easeOutBack',
			'easingOut'				: 'easeInBack'
		}); 

		$("div.profilev > a > img").css('height', '133px');
		$("div.profileh > a > img").css('width', '133px');

		scaleJobPics = function() {

			$('#viewport img').load(function() {

				$('#viewport img').each(function() {
					var maxWidth = 500; // Max width for the image
					var maxHeight = 500;    // Max height for the image
					var ratio = 1;  // Used for aspect ratio
					var width = $(this).width();    // Current image width
					var height = $(this).height();  // Current image height
			 
					// Check if the current width is larger than the max
					if(width > maxWidth){
						ratio = maxWidth / width;   // get ratio for scaling image
						$(this).css("width", maxWidth); // Set new width
						$(this).css("height", height * ratio);  // Scale height based on ratio
						height = height * ratio;    // Reset height to match scaled image
					}
			 
					// Check if current height is larger than max
					if(height > maxHeight){
						ratio = maxHeight / height; // get ratio for scaling image
						$(this).css("height", maxHeight);   // Set new height
						$(this).css("width", width * ratio);    // Scale width based on ratio
						width = width * ratio;    // Reset width to match scaled image
					}
				
				});
			
			});
	  	}

		$("img").pngfix();		

	});

	

	
