QNetworkRequest works for HTTP, but not HTTPS
So, I'm using a QNetworkRequest to get request from my website.
This is the code:
Code:
QNetworkRequest WebContact::getRequest()
{
QNetworkRequest request;
request.
setUrl(QUrl(contactURL
));
request.
setHeader(QNetworkRequest
::ContentTypeHeader,
QVariant("application/x-www-form-urlencoded"));
return request;
}
When running on Qt Creator, the contactURL works perfectly both for HTTP and HTTPS.
However, when I compile and run outside Qt Creator, only the HTTP that works. Am I forgetting to add a library or something?
Re: QNetworkRequest works for HTTP, but not HTTPS
Do you have OpenSSL libraries in your path?
Re: QNetworkRequest works for HTTP, but not HTTPS
Quote:
Originally Posted by
wysota
Do you have OpenSSL libraries in your path?
I don't know.