Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Facebook videos if protocol isn't specified in data-href (#1411)
Embedded Facebook videos are created by having a div element in the page that has (amongst other attributes) a data-href attribute that specifies the video's URL. The Facebook SDK then uses that to create the video iframe. Our "surrogate script" does the same. It turns out that when the protocol prefix of that URL isn't specified (e.g. the URL starts '//'), then the SDK and our surrogate script need to take care to add the correct protocol to the URL (e.g. 'http:' or 'https:') based on the window location. Otherwise, the video fails to load.
- Loading branch information