Search code examples
qtqtwebkitqwebview

How to set cache drive on network for QWebView caching


I am using QWebView to display my web content, I wanted to setup cache capability for my webview for that I wanted to set cache drive, but I dont have enough memory available at my client side, how can I give some folder location located at my server.


Solution

  • Use QNetworkDiskCache. Create one and assign it to an instance of QNetworkAccessManager (which gets used through the web page object, see QWebPage::setNetworkAccessManager).