View Single Post
Old 08-04-2017, 12:27 AM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,423
Karma: 27757236
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Just to get you started, here is the login code:

Code:
    needs_subscription = 'optional'

    def get_browser(self):
        br = BasicNewsRecipe.get_browser(self)
        if self.username and self.password:
            br.open('http://m.lesechos.fr/abonnement/login.php')
            br.select_form(name="frmFusion")
            br['USER'] = self.username
            br['PASS'] = self.password
            br.submit()
        return br
I haven't tested it, it is based on inspecting the source code of the login page.

Then you need to write a parse_index() function to get the articles from the page you linked to. See https://manual.calibre-ebook.com/news.html
kovidgoyal is offline   Reply With Quote