1
0
mirror of https://github.com/l1ving/youtube-dl synced 2024-12-21 21:22:50 +08:00

[faz] Use a regex for getting the description

The page cannot be parsed in python2.6 with the html parser.
This commit is contained in:
Jaime Marquínez Ferrándiz 2013-10-27 14:18:55 +01:00
parent 749a4fd2fd
commit af4d506eb3

View File

@ -5,8 +5,6 @@ import xml.etree.ElementTree
from .common import InfoExtractor
from ..utils import (
determine_ext,
clean_html,
get_element_by_attribute,
)
@ -47,12 +45,12 @@ class FazIE(InfoExtractor):
'format_id': code.lower(),
})
descr_html = get_element_by_attribute('class', 'Content Copy', webpage)
descr = self._html_search_regex(r'<p class="Content Copy">(.*?)</p>', webpage, u'description')
info = {
'id': video_id,
'title': self._og_search_title(webpage),
'formats': formats,
'description': clean_html(descr_html),
'description': descr,
'thumbnail': config.find('STILL/STILL_BIG').text,
}
# TODO: Remove when #980 has been merged