MrJattParser.py 文件源码

python
阅读 18 收藏 0 点赞 0 评论 0

项目:song-cli 作者: ankitmathur3193 项目源码 文件源码
def list_of_all_href(self,html):
        '''
        It will return all hyper links found in the mr-jatt page for download
        ''' 
        soup=BeautifulSoup(html)
        links=[]
        a_list=soup.findAll('a','touch')
        for x in xrange(len(a_list)-1):
            link = a_list[x].get('href')
            name = a_list[x]
            name = str(name)
            name=re.sub(r'<a.*/>|<span.*">|</span>|</a>|<a.*html">|<font.*">|</font>','',name)
            name=re.sub(r'^[0-9]+\.','',name)
            links.append([link,name])

        #quit()
        return links
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号