diff options
author | Yen Chi Hsuan <yan12125@gmail.com> | 2016-03-25 16:17:54 +0800 |
---|---|---|
committer | Yen Chi Hsuan <yan12125@gmail.com> | 2016-03-26 17:47:32 +0800 |
commit | 5964b598ff536c32198181e5027610f3d9a474bb (patch) | |
tree | 2f5f4de55e316c62b650523f02b76bb2373b7249 /youtube_dl | |
parent | 62cdb96f51eca4226b4d499e292d1ea1f9babb72 (diff) |
[brightcove] Support alternative BrightcoveExperience layout
The full URL lays in the `data` attribute of <object> (#8862)
Diffstat (limited to 'youtube_dl')
-rw-r--r-- | youtube_dl/extractor/brightcove.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/youtube_dl/extractor/brightcove.py b/youtube_dl/extractor/brightcove.py index 59e8008f9..afe081d82 100644 --- a/youtube_dl/extractor/brightcove.py +++ b/youtube_dl/extractor/brightcove.py @@ -136,13 +136,16 @@ class BrightcoveLegacyIE(InfoExtractor): else: flashvars = {} + data_url = object_doc.attrib.get('data', '') + data_url_params = compat_parse_qs(compat_urllib_parse_urlparse(data_url).query) + def find_param(name): if name in flashvars: return flashvars[name] node = find_xpath_attr(object_doc, './param', 'name', name) if node is not None: return node.attrib['value'] - return None + return data_url_params.get(name) params = {} |