projects
/
mir.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f211e71
)
add no-cache Pragma and Cache-control headers to the http response.. I see no reason...
author
mh
<mh>
Fri, 6 Dec 2002 07:14:45 +0000
(07:14 +0000)
committer
mh
<mh>
Fri, 6 Dec 2002 07:14:45 +0000
(07:14 +0000)
source/Mir.java
patch
|
blob
|
history
source/OpenMir.java
patch
|
blob
|
history
diff --git
a/source/Mir.java
b/source/Mir.java
index
545d85f
..
3149f83
100755
(executable)
--- a/
source/Mir.java
+++ b/
source/Mir.java
@@
-58,17
+58,7
@@
import java.util.Locale;
* Mir.java - main servlet, that dispatches to servletmodules
*
* @author $Author: mh $
* Mir.java - main servlet, that dispatches to servletmodules
*
* @author $Author: mh $
- * @version $Revision: 1.17.2.2 $ $Date: 2002/11/25 21:59:47 $
- *
- * $Log: Mir.java,v $
- * Revision 1.17.2.2 2002/11/25 21:59:47 mh
- * use req.getContextPath to find the RootUri.. much more robust. 4.0 and 4.1 compatible due to new web.xml mapping
- *
- * Revision 1.17.2.1 2002/09/01 21:31:39 mh
- * Mir goes GPL
- *
- * Revision 1.17 2002/07/21 22:27:39 mh
- * make the user error msg look nicer
+ * @version $Revision: 1.17.2.3 $ $Date: 2002/12/06 07:14:45 $
*
*/
*
*/
@@
-109,6
+99,14
@@
public class Mir extends AbstractServlet {
session = req.getSession(true);
if (req.getServerPort() == 443) http = "https"; else http = "http";
session = req.getSession(true);
if (req.getServerPort() == 443) http = "https"; else http = "http";
+
+ //nothing in Mir can or should be cached as it's all dynamic...
+ //
+ //this needs to be done here and not per page (via meta tags) as some
+ //browsers have problems w/ it per-page -mh
+ res.setHeader("Pragma", "no-cache");
+ res.setDateHeader("Expires", 0);
+ res.setHeader("Cache-Control", "no-cache");
res.setContentType("text/html; charset="
+MirConfig.getProp("Mir.DefaultEncoding"));
String moduleName = req.getParameter("module");
res.setContentType("text/html; charset="
+MirConfig.getProp("Mir.DefaultEncoding"));
String moduleName = req.getParameter("module");
diff --git
a/source/OpenMir.java
b/source/OpenMir.java
index
912a666
..
7339d66
100755
(executable)
--- a/
source/OpenMir.java
+++ b/
source/OpenMir.java
@@
-90,6
+90,13
@@
public class OpenMir extends AbstractServlet {
setLanguage(session,getAcceptLanguage(req));
}
setLanguage(session,getAcceptLanguage(req));
}
+ //nothing in Mir can or should be cached as it's all dynamic...
+ //
+ //this needs to be done here and not per page (via meta tags) as some
+ //browsers have problems w/ it per-page -mh
+ res.setHeader("Pragma", "no-cache");
+ res.setDateHeader("Expires", 0);
+ res.setHeader("Cache-Control", "no-cache");
res.setContentType("text/html; charset="
+MirConfig.getProp("Mir.DefaultEncoding"));
try {
res.setContentType("text/html; charset="
+MirConfig.getProp("Mir.DefaultEncoding"));
try {