Quote:
Originally Posted by kidtwisted
A question about preprocess_html part.
What does the "3" represent in this line?
Code:
self.append_page(soup, soup.body, 3)
|
It's "position" in the insert here: appendtag.insert(position,texttag)
It's saying to insert the text at the 3rd tag position. You can reference locations in Soup by labels (most common) or by tag position number (as above).
Quote:
Thanks for your help, just needs a little more clean up.
I need to apply this to the pcper.com site now , it's a little more tricky so it might need a different approach.
Thanks again.
|
You're welcome and good luck. I prefer to help others figure out how to do it than to just write it. If you need help with pcper, let us know, and be sure to post your final results here so Kovid can add it to the code for use by others.