fix bug #473 can't parse ledirect url

This commit is contained in:
Juke 2011-02-05 13:21:49 +01:00 committed by Romain Bignon
commit 119df19f5b
5 changed files with 119 additions and 31 deletions

View file

@ -16,6 +16,7 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
from .pages.article import ArticlePage
from .pages.ledirect import LeDirectPage
from weboob.tools.browser import BaseBrowser
__all__ = ['Newspaper20minutesBrowser']
@ -23,9 +24,14 @@ __all__ = ['Newspaper20minutesBrowser']
class Newspaper20minutesBrowser(BaseBrowser):
PAGES = {
'http://www.20minutes.fr/article/?.*': ArticlePage
'http://www.20minutes.fr/article/?.*': ArticlePage,
'http://www.20minutes.fr/ledirect/?.*': LeDirectPage
}
def is_logged(self):
return False
def get_content(self, url):
self.location(url)
return self.page.article