but try coping this as is to your code:
Code:
def preprocess_html(self, soup):
newsbody= soup.find('div',attrs={'id':'newsbody'})
newsblocks=nesbody.find('div',attrs=['id':'newsblocks'])
newsbody.insert(-1, newsblocks)
return soup
edit:
i thought of it again, you may want to try this instead:
Code:
def preprocess_html(self, soup):
newsblocks=soup.find('div',attrs=['id':'newsblocks'])
soup.find('div',attrs={'id':'newsbody'}).insert(-1, newsblocks)
return soup
tell me which one of them worked (if at all)