aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl
diff options
context:
space:
mode:
authorhuohuarong <huohuarong@gmail.com>2013-08-06 10:26:57 +0800
committerhuohuarong <huohuarong@gmail.com>2013-08-06 10:26:57 +0800
commitd5b00ee6e0ba70fd5d87752e8772fc1c39e4bd59 (patch)
tree8ac6bb32bac4dde4d338a84f87a8096d61b18b16 /youtube_dl
parentb5a6d408181c118bf51382f486a2492643ed74ec (diff)
improve sohu extractor
Diffstat (limited to 'youtube_dl')
-rw-r--r--youtube_dl/extractor/sohu.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/youtube_dl/extractor/sohu.py b/youtube_dl/extractor/sohu.py
index cd049b6f0..24fc3a5d7 100644
--- a/youtube_dl/extractor/sohu.py
+++ b/youtube_dl/extractor/sohu.py
@@ -31,6 +31,7 @@ class SohuIE(InfoExtractor):
compiled = re.compile(pattern, re.DOTALL)
title = self._search_regex(compiled, webpage, u'video title')
title = clean_html(title).split('-')[0].strip()
+ self.to_screen('Title: %s' % title)
pattern = re.compile(r'var vid="(\d+)"')
result = re.search(pattern, webpage)
if not result:
@@ -70,6 +71,7 @@ class SohuIE(InfoExtractor):
base_url_3 = 'http://allot/?prot=prot&file=clipsURL[i]&new=su[i]'
files_info = []
for i in range(num_of_parts):
+ self.to_screen('Geting json infomation of part %s/%s' % (i + 1, num_of_parts))
middle_url = 'http://%s/?prot=%s&file=%s&new=%s' % (allot, prot, clipsURL[i], su[i])
logging.info('middle url part %d: %s' % (i, middle_url))
middle_info = urllib2.urlopen(middle_url).read().split('|')