Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Recipes

Notices

Reply
 
Thread Tools Search this Thread
Old 11-01-2010, 05:15 PM   #16
marbs
Zealot
marbs began at the beginning.
 
Posts: 122
Karma: 10
Join Date: Jul 2010
Device: nook
i would love it if you could share the code you built. i am stuck on trying to append the article.text_summary to feeds. it keeps telling me that i am missing a title element. i tried feeds.append((title,textsum)) when title='1' and textsum is a list of article.text_summary. no go at all.
marbs is offline   Reply With Quote
Old 11-03-2010, 03:47 PM   #17
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by marbs View Post
i would love it if you could share the code you built. i am stuck on trying to append the article.text_summary to feeds. it keeps telling me that i am missing a title element. i tried feeds.append((title,textsum)) when title='1' and textsum is a list of article.text_summary. no go at all.
I'm not sure what you are trying to do above. I didn't append anything to feeds and I don't know why you would want to? (I'm not at the machine with the test code on it, and it's currently being restored to an earlier state - I think a hardware problem)

Is this not clear? ...
"I put an article_title_list = [] and index n = 0 outside the functions, then used self.article_title_list.append(article.text_summar y) inside parse_feeds and self.article_title_list[self.n] inside postprocess_html to access it and self.n = self.n + 1 inside postprocess_html to increment the index. "
Starson17 is offline   Reply With Quote
Old 11-03-2010, 04:27 PM   #18
marbs
Zealot
marbs began at the beginning.
 
Posts: 122
Karma: 10
Join Date: Jul 2010
Device: nook
i think i got it this time.

i am still a bit lost with the local and global variables in python....
marbs is offline   Reply With Quote
Old 11-03-2010, 05:00 PM   #19
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by marbs View Post
i think i got it this time.

i am still a bit lost with the local and global variables in python....
I'm certainly no expert in Python either. However, you do need to get the title out of parse_feeds, where it's local, and into the html processing. parse_feeds will be long gone by the time html processing (pre or post) begins, and it gets restarted for each article.
Starson17 is offline   Reply With Quote
Old 11-03-2010, 05:21 PM   #20
marbs
Zealot
marbs began at the beginning.
 
Posts: 122
Karma: 10
Join Date: Jul 2010
Device: nook
that makes a lot of sense.

i think i got it more or less. the recipe that is.
the descriptions are one off from the article, but that is peanuts.

and the recipe is downloaded and i did it. thank you very much. you have no idea how much this helps me....
marbs is offline   Reply With Quote
Old 11-03-2010, 10:11 PM   #21
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by marbs View Post
thank you very much. you have no idea how much this helps me....
You're welcome. I'm glad to help.
Starson17 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump


All times are GMT -4. The time now is 04:32 AM.


MobileRead.com is a privately owned, operated and funded community.