mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2024-11-25 19:52:11 +00:00
Request video info webpage using "embedded" instead of "detailpage"
In the request for get_video_info, use el=embedded instead of el=detailpage, as if the request was coming from an embedded video player instead of the video webpage. This created problems for some videos, with YouTube replying with "Invalid parameters". This fixes issue #109 and fixes issue #110.
This commit is contained in:
parent
eaf4a7288d
commit
2ed1ddd0a0
1 changed files with 1 additions and 1 deletions
|
@ -783,7 +783,7 @@ class YoutubeIE(InfoExtractor):
|
||||||
video_extension = self._video_extensions.get(format_param, 'flv')
|
video_extension = self._video_extensions.get(format_param, 'flv')
|
||||||
|
|
||||||
# Get video info
|
# Get video info
|
||||||
video_info_url = 'http://www.youtube.com/get_video_info?&video_id=%s&el=detailpage&ps=default&eurl=&gl=US&hl=en' % video_id
|
video_info_url = 'http://www.youtube.com/get_video_info?&video_id=%s&el=embedded&ps=default&eurl=&gl=US&hl=en' % video_id
|
||||||
request = urllib2.Request(video_info_url, None, std_headers)
|
request = urllib2.Request(video_info_url, None, std_headers)
|
||||||
try:
|
try:
|
||||||
self.report_video_info_webpage_download(video_id)
|
self.report_video_info_webpage_download(video_id)
|
||||||
|
|
Loading…
Reference in a new issue