Quantcast
Channel: Jobs
Viewing all articles
Browse latest Browse all 18427

QWebView. How to make a simple POST request.

$
0
0
Hello! I tried to make a simple POST request using QWebView, but my PHP side saying that it is a GET :( My QT code: ui->mainWebViewInfoWnd->             load(QNetworkRequest(QUrl(QString("http://176.111.***.93/info"))),                  QNetworkAccessManager::PostOperation,                  QByteArray("key=value")); My PHP code: <?php if ($_SERVER['REQUEST_METHOD'] == 'POST') {       echo 'POST :)'; } else {       echo 'GET :('; } ?> As a result in my QWebView frame I got: “GET :(”

Viewing all articles
Browse latest Browse all 18427

Trending Articles