目前在学习Python的数据抓取(爬虫),突发奇想,如果在豆瓣抓取到电影名称后,如何通过获取的电影名称抓取对应的视频URL呢?
本人的流程如下:
1、去豆瓣抓取部分电影名称
2、保存到数据库
3、通过数据库保存的名称去优酷等网站搜索相关电影
4、获取相关电影的视频链接地址
5、把链接地址保存到对应的数据表中。
不知大神有何建议?为感。
怪我咯2017-04-18 10:23:10
Each video website obtains the video address in a different way, and each needs to write a corresponding capture method. And like Youku, larger videos are generally segmented, even if there may be several URLs, this also needs to be considered.
伊谢尔伦2017-04-18 10:23:10
You can get it directly from major video sites. Why do you need to get the name from Douban? score?
Under normal circumstances, it is possible, but you need to control the number of results obtained. For example, if you search for a movie, there may be many results.
天蓬老师2017-04-18 10:23:10
If you are crawling Douban movies, they usually have playback sources, and you can directly crawl the URL