Parse HTML with CSS or XPath selectors?
Posted
by ovolko
on Stack Overflow
See other posts from Stack Overflow
or by ovolko
Published on 2010-04-11T16:31:42Z
Indexed on
2010/04/11
16:33 UTC
Read the original article
Hit count: 314
My goal is to parse HTML with lxml, which supports both XPath and CSS selectors.
I can tie my model properties either to CSS or XPath, but I'm not sure which one would be the best, e.g. less fuss when HTML layout is changed, simpler expressions, greater extraction speed.
What would you choose in such a situation?
© Stack Overflow or respective owner