tags:

views:

127

answers:

2

I'm not interested in the QNetWork class and all it's callbacks, I want a static function or something where I can just:

QString html = QHttpHelperThingy::fetch("http://blah.com");

Does such a thing exist?

+1  A: 

QHttp exists and approximately works as you expect it to, but it's been declared obsolete. I have not found any replacement for it so far.

Benoît
+1, I don't find any replacement either, and QnetworkAccessManager does not provide the same level of control
penguinpower
+1  A: 

I believe that this is the replacement path: http://doc.trolltech.com/4.6/qnetworkaccessmanager.html, but QHttp will work throughout 4.x series.

e8johan
Yes, with QNetworkAccessManager you can do it in 3 or 4 lines and one slot for the finished() signal.Do not use QHttp.
guruz