【发布时间】:2017-05-15 00:21:48
【问题描述】:
从这个标签中获取背景
<body style="background-image: url("http://www.auchandrive.fr/drive/static-media/public2/zones_edit/bannieres/_2016/S49/background_festif2016_boutique.jpg")
我在 Selenium 中使用此代码
background = driver.find_element_by_css_selector('body').value_of_css_property('background-image')
我如何使用 Css Selector 或 Xpath 在 Scrapy 中使用它?
【问题讨论】:
标签: selenium xpath css-selectors scrapy selector