Hello Dirk, The problem is that the browser caches the images - it sees the URL and then decides that it already downloaded the image.
You're right in your solution: the filename must change to force the browser to download the new file. However, Wt offers a method that is less intrusive than putting hundreds of files in a temporary directory. See the documentation of WResource, and more specifically WFileResource (or WMemoryResource). These resources will change their URL every time that their contents are changed, and the elements refering to them (WImage/WAnchor/...) will also automatically be updated. Regards, Wim. 2011/11/21 Dirk Eddelbuettel <e...@debian.org>: > Dirk Eddelbuettel <edd@...> writes: >> This all works fine, and the new image gets generated. But I am having a >> hard >> to get Wt to refresh the image, and to send a new one to the browser. How >> can >> I force this? I tried >> >> img_->setImageRef(m_tempfile); >> img_->setMargin(5, Top | Bottom); >> img_->refresh(); >> img_->show(); >> >> but no luck. Now, m_tempfile is currently a 'fixed' file. Should I make it a >> new tempfile for each invocation? > > Turns out that that solves the issue, somewhat---I get fresh and updated > displays. > > Is there a way to simulate the effect of a new file, without requiring an > actual new file? Splattering the temp directories with tempfiles is a > little inelegant, but maybe the only may to do this. > > Dirk > > > > > ------------------------------------------------------------------------------ > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > _______________________________________________ > witty-interest mailing list > witty-interest@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/witty-interest > ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d _______________________________________________ witty-interest mailing list witty-interest@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/witty-interest