Python-100-Days/Day66-75/code/example10.py

13 lines
275 B
Python
Raw Normal View History

2018-06-04 00:31:38 +08:00
import robobrowser
2018-06-02 13:19:54 +08:00
def main():
2018-06-04 00:31:38 +08:00
b = robobrowser.RoboBrowser(parser='lxml')
b.open('https://v.taobao.com/v/content/live?catetype=704&from=taonvlang')
for img_tag in b.select('img[src]'):
print(img_tag.attrs['src'])
2018-06-02 13:19:54 +08:00
if __name__ == '__main__':
2018-06-04 00:31:38 +08:00
main()