This commit is contained in:
Kovid Goyal 2011-02-11 13:14:40 -07:00
commit 2d00173e9e

View File

@ -182,6 +182,10 @@ class NYTimes(BasicNewsRecipe):
'mediaOverlay slideshow',
'headlinesOnly multiline flush',
'wideThumb',
'video', #added 02-11-2011
'videoHeader',#added 02-11-2011
'articleInlineVideoHolder', #added 02-11-2011
'assetCompanionAd',
re.compile('^subNavigation'),
re.compile('^leaderboard'),
re.compile('^module'),
@ -664,7 +668,7 @@ class NYTimes(BasicNewsRecipe):
try:
#remove "Related content" bar
runAroundsFound = soup.findAll('div',{'class':['articleInline runaroundLeft','articleInline doubleRule runaroundLeft','articleInline runaroundLeft firstArticleInline']})
runAroundsFound = soup.findAll('div',{'class':['articleInline runaroundLeft','articleInline doubleRule runaroundLeft','articleInline runaroundLeft firstArticleInline','articleInline runaroundLeft ']})
if runAroundsFound:
for runAround in runAroundsFound:
#find all section headers
@ -672,6 +676,12 @@ class NYTimes(BasicNewsRecipe):
if hlines:
for hline in hlines:
hline.extract()
#find all section headers
hlines = runAround.findAll('h6')
if hlines:
for hline in hlines:
hline.extract()
except:
self.log("Error removing related content bar")