From 8f7d05be6d40f30f1ec62a4069aa93d6d4514f38 Mon Sep 17 00:00:00 2001 From: Vladimir Shabanov Date: Wed, 12 Sep 2012 19:49:02 +0400 Subject: Fixed HTTP date format and added Cache-Control to app.js --- src/cjr_print.sml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/cjr_print.sml b/src/cjr_print.sml index c1198ccf..33980f69 100644 --- a/src/cjr_print.sml +++ b/src/cjr_print.sml @@ -3239,7 +3239,7 @@ fun p_file env (ds, ps) = val now = Time.now () val nowD = Date.fromTimeUniv now - val rfcFmt = "%a, %d %b %Y %H:%M:%S" + val rfcFmt = "%a, %d %b %Y %H:%M:%S GMT" in box [string "#include \"", string (OS.Path.joinDirFile {dir = !Settings.configInclude, @@ -3430,6 +3430,8 @@ fun p_file env (ds, ps) = newline, string ("uw_write_header(ctx, \"Last-modified: " ^ Date.fmt rfcFmt nowD ^ "\\r\\n\");"), newline, + string ("uw_write_header(ctx, \"Cache-Control: max-age=31536000, public\\r\\n\");"), + newline, string "uw_write(ctx, jslib);", newline, string "return;", -- cgit v1.2.3