View Single Post
Old 08-08-2019, 09:16 AM   #11
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,922
Karma: 6240958
Join Date: Nov 2009
Device: many
Note lxml will parse both pure xml and html. You have to tell it which one to use by telling it which builder or parser to use. And you should also use an appropriate serializer. If you try to use an html parser and serializer on a pure xml fragment you will end up with exactly the error you reported.

KevinH

Quote:
Originally Posted by Vroni View Post
Hi, thx for the example. I'm pretty sure i've tested my code with lxml as parser and got the html and body elements as well. But i will try this again and see what i did wrong as soon as my Sigiil installation is working again
KevinH is offline   Reply With Quote