- QString httpGet(QUrl url){
- QNetworkAccessManager *manager = new QNetworkAccessManager();
- QNetworkReply *http = manager->get(QNetworkRequest(url));
- QEventLoop eventLoop;
- QObject::connect(http,SIGNAL(finished()),&eventLoop, SLOT(quit()));
- eventLoop.exec();
- return QString::fromUtf8(http->readAll());
- }