﻿$(document).ready(function() {
$("a.youtube").click(function() {
$.fancybox({
'padding'       : 0, //optional
'autoScale'     : false,
'transitionIn': 'none',
'transitionOut': 'none',
'title': this.title,
'width': 640, //or whatever
'height': 386, //or whatever
'href': this.href.replace(new RegExp("watch\\?v=", "i"), 'v/'),
'type': 'swf',
'swf': {
'wmode': 'opaque',
'allowfullscreen'       : 'true'
}
});
return false;
});
}); //ready


$(document).ready(function() {
$("a.iframe").fancybox({
'width'				: '7',
'height'				: '60%',
'autoScale'			: false,
'transitionIn'		: 'none',
'transitionOut'		: 'none',
'type'				: 'iframe'
});
});


$("#login").fancybox({
	'scrolling'		: 'no',
	'titleShow'		: false,
	'onClosed'		: function() {
	    $("#login_error").hide();
	}
});
