From 9eabd017b4e7306bf59a9ef5776ed1d5a297e469 Mon Sep 17 00:00:00 2001 From: emkael Date: Fri, 31 Oct 2014 21:51:55 +0100 Subject: * ChicaneF1 title extraction --- dumps/_sites/chicane-f1.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'dumps') diff --git a/dumps/_sites/chicane-f1.py b/dumps/_sites/chicane-f1.py index 07d90c9..b308d44 100644 --- a/dumps/_sites/chicane-f1.py +++ b/dumps/_sites/chicane-f1.py @@ -7,7 +7,7 @@ from lxml import html def fetch(url): contents = urllib2.urlopen(url).read() tree = html.fromstring(contents) - title = tree.xpath("//title")[0].text + title = tree.xpath("//h1")[0].text + ' - ' + tree.xpath('//span[@class="subtitle"]')[0].text tables = tree.xpath("//table[@cellpadding=6]") print url print title -- cgit v1.2.3