KHtmlPart caching images, how to disable?

Unai Garro Unai.Garro at ee.ed.ac.uk
Sun Jul 27 18:25:28 BST 2003


>of course you can. check URLArgs for a parameter called "reload".

Hi Dirk, thanks for the hint, but still KHTMLPart doesn't reload the images. I 
tried the following, which I think is the correct way to use it

============
KParts::URLArgs args (dataView->browserExtension()->urlArgs());
args.reload=true; // Do not use cache
dataView->browserExtension()->setURLArgs(args); // set the args to the part

dataView->begin(KURL("file:/tmp/" )); // Initialize to /tmp directory
dataView->write(dataHTML); // Write the html code
dataView->end();


The only way I found so far to reload was:

delete dataView; // Destroy the part
dataView =new KHTMLPart(this); // create new part
dataView->begin(KURL("file:/tmp/" )); // Initialize to /tmp directory
dataView->write(recipeHTML);
dataView->end();




More information about the kfm-devel mailing list