一次性提取指定多标签里的所有文字。string()
bloger = selector.xpath("//a[@class='author-name blue-link']")
print(bloger[0].xpath('string(.)').strip())>>> from lxml import etree
>>> result = html.xpath("//td")
>>> tds[3].xpath('string(.)').strip().replace("%","")
11.30%
1.28%
在xpath语法里面,点(.)表示当前节点.