Thanks for feedback - new to forum so still learning.
Hopefully I've added the recipe code correctly this time.
Quote:
Originally Posted by Starson17
What happens when you click on the index.html in the first directory? Does Firefox allow you to click through to the articles and see the article content? (As dwanthny said, if you had used CODE tags, it would have been easier to run your recipe to check it out.)
|
Yes, Firefox does allow me to click through to the articles and see the article content. I've since ceated a second recipe for another site (which does not require a login so only used the Basic Add New Recipe page in Calibre) and that worked first time (apart from possibly needing a bit of pruning).
Code:
from calibre.web.feeds.news import BasicNewsRecipe
import re
class AdvancedUserRecipe1282596648(BasicNewsRecipe):
title = u'Ilkeston Advertsier'
oldest_article = 7
max_articles_per_feed = 100
needs_subscription = True
def get_browser(self):
br = BasicNewsRecipe.get_browser()
if self.username is not None and self.password is not None:
br.open('http://auth.jpress.co.uk/login.aspx?ReturnURL=http%3a%2f%2fwww.ilkestonadvertiser.co.uk%2ftemplate%2fRegister.aspx%3fReturnURL%3dhttp%3a%2f%2fwww.ilkestonadvertiser.co.uk%2ffrontpage.aspx&SiteRef=IAS')
br.select_form(name='Form1')
br['ctl00$txtEmailAddress'] = self.username
br['ctl00$txtPassword'] = self.password
br.submit()
return br
feeds = [(u'Ilkeston Today - News', u'http://www.ilkestonadvertiser.co.uk/getfeed.aspx?sectionid=795&format=rss')]