Created
March 10, 2012 12:55
-
-
Save nicolechung/2011347 to your computer and use it in GitHub Desktop.
Fancybox: Vimeo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".vimeobox").click(function(e) { | |
e.preventDefault(); | |
var id = $(this).attr('id'); | |
var title = 0; // hide vimeo title | |
var byline = 0; // hide byline | |
var portrait = 0; // hide thumbnail portrait | |
var autoplay = 1; | |
var url = "http://player.vimeo.com/video/" + id + | |
"?title=" + title + | |
"&byline="+ byline + | |
"&portrait=" + portrait + | |
"&autoplay" + autoplay; | |
$.fancybox({ | |
'href': url, | |
'type': 'iframe', | |
'autoSize':false, | |
'fitToView':true | |
}) | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment