[Qt-interest] xpath query for webkit
Li Li
fancyerii at gmail.com
Wed Jan 26 19:02:07 CET 2011
do you mean there isn't any method to select QWebElement by XPath but
only CSS selector?
2011/1/27 Jason H <scorp1us at yahoo.com>:
> QtXmlPatterns does not use QWebElement, it only uses W3C constructs.
> You'd have to take the XML doc and deal with it in QXmlQuery independently.
> There is no cross-module integration.
>
>
>
>
>
>
> ----- Original Message ----
> From: Li Li <fancyerii at gmail.com>
> To: qt-interest at trolltech.com
> Sent: Wed, January 26, 2011 2:24:46 AM
> Subject: [Qt-interest] xpath query for webkit
>
> hi all
> I want to use qt webkit to extraction data from web page. The
> QWebElement class only has functions to select Nodes by Standard CSS2
> selector syntax.
> I'd like to do it by xpath. I can export the whole page's html by
> QWebElement::toOuterXml () function. And then use XPath in Qt to deal
> with it.
> The problem is -- I can only process Xml but can not select the QWebElement.
> e.g. I can use QWebElementCollection QWebElement::findAll ( const
> QString & selectorQuery ) const to select a QWebElement. How can I do
> this by
> XPath?
> Thanks.
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
>
>
>
>
More information about the Qt-interest-old
mailing list