<img src="<%#ImageFile%>" border='0' width="150" alt="" height="150" /> <-- Displays the image
<br />
<br />
Upload Picture: <input id="myFile" type="file" name="myFile" runat="server" size="60" />
<asp:button id="DoFileUploadBtn" Height="24" runat="server" Text="Upload" onclick="DoFileUploadBtn_Click"></asp:button>
当有人第一次上传一个图像时,它工作正常。但是,如果更改了图像,则会删除旧图像,正确上载文件并刷新页面。但是,浏览器
仍然显示旧图像。
我必须手动点击
刷新
我
做
使用NoStore和Duration=“1”的OutputCache标记(尝试)确保页面上没有任何内容被缓存,但没有效果:
<%@ OutputCache NoStore="true" Duration="1" VaryByParam="none" Location="none" %>
因此,问题是:我需要做什么来确保
新的