From: Yen Chi Hsuan Date: Fri, 25 Mar 2016 08:17:54 +0000 (+0800) Subject: [brightcove] Support alternative BrightcoveExperience layout X-Git-Url: http://git.bitcoin.ninja/?a=commitdiff_plain;h=5964b598ff536c32198181e5027610f3d9a474bb;p=youtube-dl [brightcove] Support alternative BrightcoveExperience layout The full URL lays in the `data` attribute of (#8862) --- 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 = {}