def get_playable_url(self, media_url, is_probably_a_video=False ):
if self.is_album(media_url):
log(' is an album:'+ media_url )
self.media_type = self.TYPE_ALBUM
return media_url, sitesBase.TYPE_ALBUM
log(' scraping:'+ media_url )
content = self.requests_get( media_url)
#https://github.com/downthemall/anticontainer/blob/master/plugins/imgbox.com.json
match = re.compile("id=\"img\".+?src=\"(.+?)\" title=\"(.+?)\"", re.DOTALL).findall(content.text)
#log(' match:' + repr(match))
if match:
#log(' match' + match[0][0])
self.poster_url=match[0][0]
self.thumb_url=self.poster_url
return self.poster_url, self.TYPE_IMAGE
else:
log(" %s can't scrape image " %(self.__class__.__name__ ) )
评论列表
文章目录