aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cache.manifest.php32
-rw-r--r--views/default/page_elements/header.php2
2 files changed, 33 insertions, 1 deletions
diff --git a/cache.manifest.php b/cache.manifest.php
new file mode 100644
index 000000000..db963aeef
--- /dev/null
+++ b/cache.manifest.php
@@ -0,0 +1,32 @@
+<?php
+header("Content-type: text/cache-manifest");
+
+require_once dirname(dirname(dirname(__FILE__))).'/engine/start.php';
+
+global $CONFIG;
+
+$viewtype = get_input('viewtype', 'default');
+
+$manifest = <<<MANIFEST
+CACHE MANIFEST
+# Viewtype: $viewtype
+# Lastcache: {$CONFIG->lastcache}
+
+CACHE:
+# CSS
+{$CONFIG->url}_css/css.css?lastcache={$CONFIG->lastcache}&viewtype=$viewtype
+
+# Scripts
+{$CONFIG->url}vendors/jquery/jquery-1.3.2.min.js
+{$CONFIG->url}vendors/jquery/jquery-ui-1.7.2.min.js
+{$CONFIG->url}vendors/jquery/jquery.form.js
+{$CONFIG->url}vendors/jquery/jquery.easing.1.3.packed.js
+{$CONFIG->url}_css/js.php?js=initialise_elgg&viewtype=$viewtype&lastcache={$CONFIG->lastcache}
+{$CONFIG->url}_css/js.php?js=friendsPickerv1&viewtype=$viewtype&lastcache={$CONFIG->lastcache}
+
+NETWORK:
+*
+
+MANIFEST;
+
+echo $manifest; \ No newline at end of file
diff --git a/views/default/page_elements/header.php b/views/default/page_elements/header.php
index a69f79cba..65166c3dc 100644
--- a/views/default/page_elements/header.php
+++ b/views/default/page_elements/header.php
@@ -52,7 +52,7 @@ $version = get_version();
$release = get_version(true);
?>
<!doctype html>
-<html>
+<html manifest="<?php echo $vars['url']; ?>mod/html5/cache.manifest.php?viewtype=<?php echo $vars['view']; ?>">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="ElggRelease" content="<?php echo $release; ?>" />