Hello,

I need to add ~twenty lines of HTML right after the <body> tag.

Does lxml provide a way to read that data from a variable, to keep things simple?

========
for body in root.xpath('//body[@*]'):

    et.SubElement(body,"<p>",HTML_block)
========

Thank you.

_______________________________________________
lxml - The Python XML Toolkit mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/lxml.python.org/
Member address: [email protected]

Reply via email to