I'm trying to write a simple application that will launch a browser and send it to a URL based on a user's input.
QDesktopServices::openUrl(QUrl(url));
However, I'd like to pass variables along with whatever URL they submit using POST.
For GET, all I'd need to do is simply embed the values into the URL string, but how would I go about adding POST variables?.
Thanks.
From the official documentation:
The short answer is that it was not meant to be a network managet. For that purpose, one could already use the
QNetworkAccessManager. It was just a convenient way to add support for opening up an URL as that would require quite a bit of work otherwise. There were no further plans to it to replicateQtNetworkmore closely.Thereby, I would suggest to use something like this to achieve working with post methods given your url: