LifeActor / ykdl

a video downloader focus on China mainland video sites.(一款专注于中国大陆视频网站的视频下载器。)
https://github.com/LifeActor/ykdl
Other
1.44k stars 285 forks source link

title不太友好 #105

Closed redstoneleo closed 7 years ago

redstoneleo commented 7 years ago

title不太友好,最好能用视频名称代替,有些土豆视频也会出现类似问题

C:\Users\i>ykdl -i http://www.iqiyi.com/v_19rrmtodvg.html#curid=272022400_b1820c
7412f60bdd6d0b2fb0a7df2697
site:                爱奇艺 (Iqiyi)
title:               爱奇艺 (Iqiyi)_('272022400', 'b1820c7412f60bdd6d0b2fb0a7df2
697')
artist:              None
streams:
    - format:        HD
      container:     flv
      video-profile: 540p
    # download-with: ykdl --format=HD [URL]
Real urls:
http://39.130.131.138/videos/v0/20140731/4d/56/de2e1277c6a261192b1edba8c1c58919.
f4v?key=00107d5bf602964575636230a2de13274&dis_k=0af01981c5112a43b25da6185d7c58be
1&dis_t=1490885789&dis_dz=CMNET-YunNan&dis_st=42&src=iqiyi.com&uuid=7588547f-58d
d1c9d-102&qd_aid=201383801&qd_stert=0&qd_vipres=0&qd_vipdyn=0&qd_src=01012001010
000000000&qd_ip=7588547f&qd_index=1&qd_vip=0&qd_k=370faf336b82405de28ed46475188e
2a&qd_uid=0&qd_tm=1490885789595&qd_tvid=272022400
http://39.130.131.133/videos/v0/20140731/4d/56/262273f9702f1df10c3ad9d6c0cd9949.
f4v?key=08a43ef947ae02ead3d84679620c7ce48&dis_k=01501439f67ff3943f2dfcb088776a8c
zhangn1985 commented 7 years ago

无法去的正确的title

redstoneleo commented 7 years ago

抓取网页title确定视频名称不行吗?

mengmo commented 7 years ago
ykdl -i http://www.iqiyi.com/v_19rrmtodvg.html
site:                爱奇艺 (Iqiyi)
title:               我为歌狂第6集
artist:              None
streams:
    - format:        HD
      container:     flv
      video-profile: 540p
    # download-with: ykdl --format=HD [URL]
Real urls:
zhangn1985 commented 7 years ago

这种网页很奇怪,前半部分http://www.iqiyi.com/v_19rrmtodvg.html 代表了一个视频,但真是播放的时候却是#curid=272022400_b1820c7412f60bdd6d0b2fb0a7df2697 所代表的视频。

而如果直接抓取网页这是前半部的信息。

zhangn1985 commented 7 years ago

这里只是巧合,前半部和后半部是一个视频。你可以在网页上上下集点点,前半部都是不变的,但后半部会变,网页的标题会变,但是查看网页源代码,标签却没有变化。</p> <p>所以直接从网页源码上抓取title是不可取的。</p> </div> </div> <div class="comment"> <div class="user"> <a rel="noreferrer nofollow" target="_blank" href="https://github.com/mengmo"><img src="https://avatars.githubusercontent.com/u/17815250?v=4" />mengmo</a> commented <strong> 7 years ago</strong> </div> <div class="markdown-body"> <p>这个我知道。我的意思是</p> <blockquote> <p>所以说,目前如果要下载 iqiyi 上多集的视频,建议从视频的介绍页上右键拿 URL</p> </blockquote> </div> </div> <div class="comment"> <div class="user"> <a rel="noreferrer nofollow" target="_blank" href="https://github.com/redstoneleo"><img src="https://avatars.githubusercontent.com/u/5896180?v=4" />redstoneleo</a> commented <strong> 7 years ago</strong> </div> <div class="markdown-body"> <p>大家辛苦了</p> </div> </div> <div class="comment"> <div class="user"> <a rel="noreferrer nofollow" target="_blank" href="https://github.com/redstoneleo"><img src="https://avatars.githubusercontent.com/u/5896180?v=4" />redstoneleo</a> commented <strong> 7 years ago</strong> </div> <div class="markdown-body"> <p><code>http://cache.video.qiyi.com/vms?key=fvip&src=1702633101b340d8917a69cf8a4b8c7c&tvId=612787600&vid=9d511f3dde526d66595e007e1526ca54&vinfo=0&tm=1512099&qyid=fa6b9af043dc164de6fb7b863e44a653&puid=&authKey=4803120db1904378e160fe0fbee9df58&um=0&pf=b6c13e26323c537d&thdk=&thdt=&rs=1&k_tag=1&qdx=n&qdv=2&vf=8b1e5aba0c99d39e5b06c57615603c15</code> 如果可以拼凑出这个url,那么这个问题就可以避开了,因为<code>jsonData["data"]["vi"]["vn"]</code>就是文件名,没有失误:)</p> </div> </div> <div class="page-bar-simple"> </div> <div class="footer"> <ul class="body"> <li>© <script> document.write(new Date().getFullYear()) </script> Githubissues.</li> <li>Githubissues is a development platform for aggregating issues.</li> </ul> </div> <script src="https://cdn.jsdelivr.net/npm/jquery@3.5.1/dist/jquery.min.js"></script> <script src="/githubissues/assets/js.js"></script> <script src="/githubissues/assets/markdown.js"></script> <script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.4.0/build/highlight.min.js"></script> <script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.4.0/build/languages/go.min.js"></script> <script> hljs.highlightAll(); </script> </body> </html>