什么是prevent的最佳途径网页codeD完全HTML从缓存中(没有PHP或任何服务器端语言)? [英] What is the best way to prevent a webpage coded completely in HTML (no PHP or any server side language) from caching?

查看:158
本文介绍了什么是prevent的最佳途径网页codeD完全HTML从缓存中(没有PHP或任何服务器端语言)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想通过把这两条线,这将prevent的页面被缓存,但这不是头部标签之间的情况:

I thought by placing these two lines that it would prevent the page from being cached but this is not the case between the head tags:

<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />

前面已经提到,这是在不支持PHP(或任何服务器端语言,好,这是不正确的服务器,它支持Perl脚本的cgi-bin文件夹,但我不知道Perl和没有时间从事它。)

As already mentioned this is on server that doesn't support PHP (or any server side language, well, that's not true, it has cgi-bin folder that supports perl scripts but I don't know perl and have no time to engage in it.)

我可以做别的什么prevent从缓存页面?这将缓存Firefox和IE(在Chrome或Safari没有这么多。)

What else could I do to prevent the page from caching? It caches on Firefox and IE (and not so much in Chrome or Safari.)

推荐答案

配置Web服务器的任何用于发送正确的缓存控制头。你可以不依赖于任何文档中本身。

Configure whatever webserver you use to send the right cache control headers. You can't depend on anything in the document itself.

这篇关于什么是prevent的最佳途径网页codeD完全HTML从缓存中(没有PHP或任何服务器端语言)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆