	$(document).ready(function() {
		
				$(".vids").click(function() {
					$.fancybox({
							'padding'		: 0,
							'autoScale'		: false,
							'transitionIn'	: 'none',
							'transitionOut'	: 'none',
							'title'			: this.title,
							'width'		: 680,
							'height'		: 495,
							'href'			: this.href.replace(new RegExp("watch\\?v=", "i"), 'v/'),
							'type'			: 'swf',
							'swf'			: {
								 'wmode'		: 'transparent',
								'allowfullscreen'	: 'true'
							}
						});

					return false;
				});
				$("a[rel=gallery]").fancybox({
								'titlePosition' 	: 'over',
								'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
									return '<span id="fancybox-title-over">Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '') + '</span>';
								}
							});
					$("a[rel=gallery]").fancybox({
						'transitionIn'	: 'none',
						'transitionOut'	: 'none',
						'titlePosition'	: 'over',
														'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
									return '<span id="fancybox-title-over">Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '') + '</span>';
								},

						'onComplete'	: function() {
							$("#fancybox-wrap").hover(function() {
								$("#fancybox-title").show();
							}, function() {
								$("#fancybox-title").hide();
							});
						}
						
					});
				
		});
