mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
37 lines
1.3 KiB
Python
37 lines
1.3 KiB
Python
#!/usr/bin/env python
|
|
|
|
from calibre.web.feeds.recipes import BasicNewsRecipe
|
|
|
|
class SeanHannity(BasicNewsRecipe):
|
|
cover_url = 'http://www.hannity.com/images/misc_logo.gif'
|
|
title = u"Sean Hannity Show"
|
|
__author__ = 'Rob Lammert - rob.lammert[at]gmail.com'
|
|
description = u"Articles from Sean Hannity's website, www.hannity.com"
|
|
oldest_article = 7.0
|
|
language = 'en'
|
|
max_articles_per_feed = 100
|
|
recursions = 0
|
|
encoding = 'utf8'
|
|
no_stylesheets = True
|
|
remove_javascript = True
|
|
#use_embedded_content = False
|
|
|
|
remove_tags = [
|
|
dict(name='div', attrs={'id':['header','navsprite','topminibarad','headline_bar','shadow','footer']}),
|
|
dict(name='div', attrs={'class':'rightcolumn'}),
|
|
dict(name='table', attrs={'id':'audiobox'}),
|
|
dict(name='a', attrs={'title':['Home','Shows','Guests','Photos']}),
|
|
dict(name='iframe')
|
|
]
|
|
|
|
feeds = [
|
|
('Content Feed', u'http://feeds.feedburner.com/TheSeanHannityShow-AllContent?format=xml')
|
|
]
|
|
|
|
|
|
|
|
#def print_version(self, url):
|
|
#parts=url.split('/')
|
|
#return url.replace(url, 'http://www.hannity.com/show/' + parts[4] + '/' + parts[5] + '/' + parts[6] + '?mode=print')
|
|
|