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
Each YouTube video has 4 generated images. They are predictably formatted as follows: | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/0.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/1.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/2.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/3.jpg | |
The first one in the list is a full size image and others are thumbnail images. The default thumbnail image (ie. one of 1.jpg, 2.jpg, 3.jpg) is: | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/default.jpg |
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
# Creating a Github Pages Organization Website | |
This was not exactly straightforward. No GitHub documentation directly walks you through this process - so I am documenting it here. | |
# Scenario | |
Let's say your organization is called 'AcmeWidgets' and you want to have your website at the root URL of your Github Pages website: https://acmewidges.github.io/ | |
You also want to do the following, which doesn't seem SO weird, right? | |
- You are using something like Yeoman or Jekyll to manage your organization site | |
- You want your DISTRIBUTION files to exist on a branch on your repository | |
- You want your SOURCE files to exist in another branch. |
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
// These are cross-browser implementations of addEvent and removeEvent that account for differences | |
// in how addEventListener and attachEvent are supported across W3C standards browsers, and IE < IE9 standards mode. | |
// (IE9 compatibility mode uses attachEvent, standards mode uses addEventListener). | |
// The approach here attempts to solve several problems: | |
// 1. IE's attachEvent obliterates 'this' and the 'this' in the callback becomes 'window' | |
// 2. The fix, which is to call the function as a method on the object, requires that | |
// each instance of the function be tagged individually (the guid) so that multiple listeners can be applied | |
// to the same object | |
// 3. Avoid the memory leaks associated with adding a property to the object that it did not already have |
NewerOlder