![]() |
#1 |
Enthusiast
![]() Posts: 46
Karma: 10
Join Date: Dec 2011
Device: Kindle 3
|
![]()
Let's put that I need to create a recipe from a website that does not have an rss. Let's also assume that I'm not interested at the wole website or its news, but only at one specific page. For example, look at this page:
http://www.probabiliformazioni.org/ Well, I simply need to convert this webpage, only this one, to a recipe (in which I could use the remove-tags options and so on to make this page more Kindle-friendly). IS IT POSSIBLE ON CALIBRE? It could be very useful for some TV Guide, MEteo websites and so on, that is on websites having a one and only interesting page and not an rss (or having and rss that does not include that specific page I need). Thanks, guys. |
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,195
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Use parse_index()
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Enthusiast
![]() Posts: 46
Karma: 10
Join Date: Dec 2011
Device: Kindle 3
|
Is there a tutorial for dummies?
![]() |
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,195
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
http://manual.calibre-ebook.com/news.html the real life example is an example of using parse_index()
|
![]() |
![]() |
![]() |
#5 |
Connoisseur
![]() Posts: 63
Karma: 46
Join Date: Feb 2011
Device: Kindle 3 (cracked screen!); PW1; Oasis
|
Here is a recipe for some Meteo and snow reports, which may help you as Meteo sites are among those you mention. (The recipe is for use skiing in Valle d'Aosta, and collects the cross country snow reports for two sites, the webcams for those two sites, the summary snow report for Valle d'Aosta, the meteo and the meteo station map). The recipe illustrates ways of accessing various information without RSS.
Spoiler:
The first three lines are needed to use local recipe storage, which I have found the simplest way to include the webcam images and the station map (any suggestion of an easier way would be welcome) The four commented lines are left to show that I have it best to avoid auto_cleanup and stylesheet suppression, and that no encoding or INDEX variable was needed. These comments are left to remind you that your recipe may have different requirements. The keep_only_tags are those needed for this recipe. The remove_tags does nothing here, and could be commented out. Again, it is left to remind you that you may need a real remove_tags. (There is no table with id="camstable" in the html sources used) The recipe defines various file paths and saves three files in local recipe storage for later use, for the webcams and station map. Note that I have included <div id="content"> in these files, as without a tag found in the keep_only_tags these images and map would be lost. The rest of the recipe builds a feed from remote sources and these local files. Uncomment the commented articles.append() line if you would like to include the thumbnail webcam images of all sites. Some logging lines have been left in the recipe to help if the Job details are viewed. These can of course be removed. I hope this helps as a tutorial. |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Enthusiast
![]() Posts: 46
Karma: 10
Join Date: Dec 2011
Device: Kindle 3
|
Thanks. I will glance at it.
|
![]() |
![]() |
![]() |
#7 |
Old Linux User
![]() Posts: 36
Karma: 12
Join Date: Jan 2012
Device: NST
|
Also Check into the Atlantic recipe (http://bazaar.launchpad.net/~kovid/c...tlantic.recipe).
The def parse_index(self) section is written really well and pretty easy to change it for your site. |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre - Custom news sources (RSS feeds) aren't being saved in my recipes | matthewkrieger | Recipes | 8 | 08-15-2019 10:16 AM |
Calibre - Custom news sources (RSS feeds) aren't being saved in my recipes | matthewkrieger | General Discussions | 2 | 01-31-2011 12:06 PM |
Request for recipes of sites with no rss | PipSqueak | Recipes | 1 | 10-16-2010 10:05 PM |
Recipes and RSS feeds and organization questions | flyash | Calibre | 13 | 06-11-2010 03:56 AM |
Help with RSS recipes | fmma | Calibre | 1 | 06-15-2009 11:51 AM |