This commit is contained in:
Kovid Goyal 2012-02-03 08:31:39 +05:30
parent f098784f55
commit 6cd7aeb64f

View File

@ -82,6 +82,14 @@ class ChicagoTribune(BasicNewsRecipe):
url = url.partition('?')[0]
return url
def skip_ad_pages(self, soup):
text = soup.find(text='click here to continue to article')
if text:
a = text.parent
url = a.get('href')
if url:
return self.index_to_soup(url, raw=True)
def postprocess_html(self, soup, first_fetch):
# Remove the navigation bar. It was kept until now to be able to follow
# the links to further pages. But now we don't need them anymore.