From 57935b2564c082b90a60468d4c844b219118886a Mon Sep 17 00:00:00 2001 From: Yen Chi Hsuan Date: Fri, 9 Oct 2015 14:11:00 +0800 Subject: [PATCH] [extractor/common] Allow HTML5 unquoted attribute values Fixes #7108 HTML5 allows unquoted attribute values. See the "Unquoted attribute value syntax" section [1] for more information [1] http://www.w3.org/TR/html5/syntax.html --- youtube_dl/extractor/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py index dbae75406..242618c58 100644 --- a/youtube_dl/extractor/common.py +++ b/youtube_dl/extractor/common.py @@ -646,7 +646,7 @@ def _get_tfa_info(self, note='two-factor verification code'): @staticmethod def _og_regexes(prop): content_re = r'content=(?:"([^>]+?)"|\'([^>]+?)\')' - property_re = r'(?:name|property)=[\'"]og:%s[\'"]' % re.escape(prop) + property_re = r'(?:name|property)=[\'"]?og:%s[\'"]?' % re.escape(prop) template = r']+?%s[^>]+?%s' return [ template % (property_re, content_re),