View Single Post
Old 06-04-2011, 10:35 PM   #3
BRGriff
Connoisseur
BRGriff began at the beginning.
 
Posts: 58
Karma: 12
Join Date: May 2011
Location: Deland, Florida
Device: Kindle 3
IT WORKED!!! Thank you!!!

Kovid,

I was a little frustrated that you were being so cryptic, especially since I am so very new to all of this. But I want to thank you for giving me a hint and letting me learn. I did research on your suggestion to use "tag.extract()". I fumbled around but finally got it! I can not tell you how thrilling it was, even though you could have written the code while half asleep.

Code:
        def preprocess_html(self, soup): 
          for tag in soup.findAll('a'):
            tag.extract() 
          return soup
I hope it will be added to the "Recipes Reusable Code" under Remove "alink" or "inline" html tags. Of course, the posting should be under your name as you are the one who knew what to do in the first place.


I am 90% finished with my objective but still need to deal with the font size of the TOC. I will post a question about that soon.


Thank you.
















BRGriff is offline   Reply With Quote