这是我正在使用的代码:
QNetworkAccessManager *manager = new QNetworkAccessManager(this);
connect(manager, SIGNAL(finished(QNetworkReply*)),
this, SLOT(replyFinished(QNetworkReply*)));
manager->get(QNetworkRequest(QUrl("https://dl-web.dropbox.com/get/patcher/wait.txt?w=AACu6t8OAIyonlf6zpLX4VQquumCR5I5Tvukdg_e8gXGxg")));
这是我的插槽:
void MainWindow::replyFinished(QNetworkReply* reply)
{
qDebug () << reply->readAll();
}
我得到“”作为输出。有什么理由吗?
我正在尝试从此链接获取文本输出。