09-12-2012, 05:48 PM | #826 | |
hopeless n00b
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Quote:
From adapter_dramioneorg.py, the code for getting the chapter url and chapter titles appear to be as follows: Code:
# Find the chapters: for chapter in soup.findAll('a', href=re.compile(r'viewstory.php\?sid='+self.story.getMetadata('storyId')+"&chapter=\d+$")): # just in case there's tags, like <i> in chapter titles. self.chapterUrls.append((stripHTML(chapter),'http://'+self.host+'/'+chapter['href']+addurl)) Code:
<tr><td>1. <a href="viewstory.php?sid=1331&chapter=1">December 2010: Five Minutes 'til Christmas</a> <span class="cnotes"><span class="cnotes"><p>My first drabble ever!</p> <p>Drabbles are supposed to be exactly 100 words long, and often have a prompt word or phrase to use as inspiration. It is a great exercise for new and experienced authors alike.</p> <p>This particular drabble is rated G, and is quite fluffy, really.</p> <p>Enjoy!</p> <p>Prompt: <i>a </i><i>gift</i></p> </span></span></td><td class="center"><a href="reviews.php?type=ST&item=1331&chapid=4326">1</a> </td><td class="center">90</td><td class="center">412</td></tr> Thanks! |
|
09-12-2012, 07:10 PM | #827 |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
By having only one 'add_chapter_numbers' option instead of one for TOC and one for in-chapter titles, this is simplified a fair bit.
The attached version has new options: Code:
## Don't like the numbers at the start of chapter titles on some ## sites? You can use strip_chapter_numbers to strip them off. Just ## want to make them all look the same? Strip them off, then add them ## back on with add_chapter_numbers. Don't like the way it strips ## numbers or adds them back? See chapter_title_strip_pattern and ## chapter_title_add_pattern. strip_chapter_numbers:true add_chapter_numbers:true I've included default patterns for the stripping and adding that seem reasonable to me, but they're also configurable: Spoiler:
Last edited by JimmXinu; 09-13-2012 at 01:30 PM. Reason: Remove obsolete beta versions |
09-13-2012, 12:38 PM | #828 | |
hopeless n00b
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Quote:
Regarding "Update Always", if there are no new chapters, does it still re-download all the chapters before updating the epub? Reason I ask is I'd like to update some 1,500 ebooks and I reckon if it downloads all the chapters, I'd play nice and just do it in batches so as not to hammer the site. |
|
09-13-2012, 01:02 PM | #829 | |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Quote:
"Update Always" pulls the first chapter or chapter list, but the whole point behind "Update epub" is to not download chapters it already has. So an "Update Always" with no new chapters will hit the site servers 2-4 times per story, depending on the site, user/pass, etc. You might consider is adding this to your personal.ini while doing large updates: Code:
slow_down_sleep_time:2.5 |
|
09-13-2012, 01:29 PM | #830 |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Test version including new site merlinfic.dtwins.co.uk.
Assuming no new problems, this is the last test version before the next release. Last edited by JimmXinu; 09-14-2012 at 01:40 PM. Reason: Remove obsolete beta versions |
09-14-2012, 04:21 AM | #831 |
Occassional Beta Tester
Posts: 283
Karma: 3516
Join Date: Nov 2010
Location: Hungary
Device: Samsung Galaxy Tab 4 (wifi only)
|
Thanks Works fine.
Last edited by Firedancer885; 09-14-2012 at 04:45 AM. |
09-14-2012, 01:27 PM | #832 |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Version 1.6.9 - 14 Sep 2012
|
09-14-2012, 03:54 PM | #833 |
hopeless n00b
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Thanks for the update. Special request, for the next update, can you please add the following additional custom columns?
Code:
theme:Theme timeline:Timeline cliche:Cliche Thanks! |
09-14-2012, 05:44 PM | #834 | |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Quote:
Each site chooses different metadata to define. Even category and genre vary wildly from site to site. At this point I don't want to add any more new metadata 'columns' that isn't used by a significant number of sites. (I only reluctantly added Relationships metadata recently after finding that 7 sites actually do provide 'ship data and a further 13 were dedicated to a particular 'ship and could therefore be considered to have implicit 'ship data.) I have an entry on the 'wishlist' to figure out a better way for individual site-specific metadata, but it hasn't happened yet. If you like, I am willing to change the dramione.org adapter to add the theme and timeline data to genre and what you've identified as 'cliche' (and dramione.org calls 'Draco' and 'Hermione' categories) to either genre or characters. Hmmm. And you've found cover images. Good thing I diff'ed the source, since you didn't mention that. I'll include that bit either way. Can you give me URLs to a couple stories there with banner images so I can test it? |
|
09-14-2012, 06:32 PM | #835 | |
hopeless n00b
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Quote:
Don't bother adding the theme and timeline info to genre. That's what I originally did and it's just not as organized as having the info in its own custom column. Totally messed up my subject tags. Don't really fancy cleaning up my Tags every time I download a new story. I'll just keep doing the edits to my local copy. Comparing the source code is much faster and easier than frequent tag clean up. dramione.org actually has ship data for extra ships. Just didn't bother adding that as I prefer just having the main ship. I've forgotten about the covers. The cover images are more banners than covers. I actually use Generate Cover for the actual calibre covers but I still do like having the banners inside the epub. Just looked for random fics with images: http://dramione.org/viewstory.php?sid=21 http://dramione.org/viewstory.php?sid=1826 http://dramione.org/viewstory.php?sid=1734 |
|
09-14-2012, 06:51 PM | #836 |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Okay. I'll continue to think about how I might be able to add more site specific metadata to custom columns. Right now my best idea for it would be to do that configuration in personal.ini instead of the GUI config.
Thanks, I'll include that cover code in the next release. |
09-14-2012, 06:55 PM | #837 |
hopeless n00b
Posts: 5,111
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
|
09-15-2012, 02:40 AM | #838 |
Evangelist
Posts: 401
Karma: 1597305
Join Date: Mar 2010
Device: Ipod G4, MacOS 10.12, Calibre, Pocketbook Touch HD 3
|
I am having trouble downloading a story from ffnet and wasn't sure if it's an issue with the story (the formatting is...weird) or it's too long or...
http://www.fanfiction.net/s/344588/1...ardassian-Mask FDL gives the message "FFDL found 0 good and 0 bad updates". The log is empty (only contains: "Status Title Author Comment URL"). Using 0.8.68 Calibre and 1.6.8 FFDL I've said it before, but I'll say it again - this plugin is fantastic. It has changed my whole workflow and made it so much easier to download and read stuff. Thanks again for all the hard work. |
09-15-2012, 11:13 AM | #839 | |
Plugin Developer
Posts: 6,316
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Quote:
Given that ffnet wouldn't allow that content now, or indeed, for several years now (see the url and email address in there?), I'm not going to put in the effort and special coding it would take to deal with this one author and their nasty HTML. Sorry. Glad you like it, sorry I couldn't help you this time. |
|
09-15-2012, 02:50 PM | #840 |
Evangelist
Posts: 401
Karma: 1597305
Join Date: Mar 2010
Device: Ipod G4, MacOS 10.12, Calibre, Pocketbook Touch HD 3
|
No worries - I thought it might have been the formatting (which is bizarre). I can get it (the story) on PDF but I think FFDL is spoiling me for other formats (and I've hated PDFs since my Palm Pilot days).
Thanks again! |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] Count Pages | kiwidude | Plugins | 1750 | 04-07-2024 01:20 AM |
[GUI Plugin] Open With | kiwidude | Plugins | 403 | 04-01-2024 08:39 AM |
[GUI Plugin] Resize Cover | kiwidude | Plugins | 95 | 03-16-2024 11:55 PM |
[GUI Plugin] Find Duplicates | kiwidude | Plugins | 1096 | 03-16-2024 11:28 PM |
[GUI Plugin] Plugin Updater **Deprecated** | kiwidude | Plugins | 159 | 06-19-2011 12:27 PM |