$(document).ready(function() {

	$("a[rel=pics]").fancybox({
		'transitionIn'		: 'elastic',
		'transitionOut'		: 'elastic',
		'titlePosition'		: 'over',
		'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
			/*return '<span >Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '') + '</span>';*/
			return '<div id="title"><p id="name">' + (title.length ? title : '' ) + '</p><p id="number">'  + 'Image ' + (currentIndex + 1) + ' of ' + currentArray.length + '</p><p><a href="javascript:;" onclick="$.fancybox.close();"><img class="noborder" src="./i/ui/closelabel.png" /></a></p></div>';
			}
	});


});
