Created
January 30, 2012 06:03
-
-
Save davidbanham/1702844 to your computer and use it in GitHub Desktop.
Piece of VideoJS behaving strangely
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
// Adjust for jQuery ID syntax | |
if (id.indexOf("#") === 0) { | |
id = id.slice(1); | |
} | |
// If a player instance has already been created for this ID return it. | |
console.log(_V_.players); // Object that appears to have one property Class named example_video_1 | |
console.log(id); // example_video_1 | |
console.log(_V_.players[id]); // undefined | |
if (_V_.players[id]) { | |
console.log('This never fires'); // Does what it says on the tin | |
return _V_.players[id]; | |
// Otherwise get element for ID | |
} else { | |
tag = _V_.el(id) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment