[Qt-jambi-interest] QNetworkAccessManager: don't cache document

Helge Fredriksen hf at poseidon.no
Tue Dec 15 20:45:30 CET 2009


I think it's better to post some real code that highlights the problem, but
keep it short...

Helge

On Tue, Dec 15, 2009 at 12:09 PM, Serg_HD <serg_hd at mail.ru> wrote:

> Hi,
> I don't want to cache concrete image on website page (using many qwebview
> for one site). For this I overload QNetworkAccessManager's method
> createRequest(), make condition for my image (if (myReq.url() == myUrl) then
> not apply
> cache), and try in this condition:
> 1) myReq.setRawHeader( new QByteArray("Cache-Control"), new
> QByteArray("no-cache") ); //not work,
> 2) myReq.setRawHeader( new QByteArray("If-Modified-Since""), new
> QByteArray(myTime) ); //not work
> 3) myReq.setUrl(new QUrl(url2 + "&x=" + rand.nextInt(1000000))); //not work
> too, url becomes really other, but however
> image in cache.
>
> How I must abolish cash for document (in my case - image)? Thanks.
> _______________________________________________
> Qt-jambi-interest mailing list
> Qt-jambi-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-jambi-interest
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-jambi-interest/attachments/20091215/72439865/attachment.html 


More information about the Qt-jambi-interest mailing list