(window.webpackJsonp=window.webpackJsonp||[]).push([[1267],{1674:function(t,a,e){"use strict";e.r(a);var s=e(31),n=Object(s.a)({},(function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("ContentSlotsDistributor",{attrs:{"slot-key":t.$parent.slotKey}},[e("h1",{attrs:{id:"html-5-cache"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#html-5-cache"}},[t._v("#")]),t._v(" HTML 5 Cache")]),t._v(" "),e("h2",{attrs:{id:"basic-example-of-html-5-cache"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#basic-example-of-html-5-cache"}},[t._v("#")]),t._v(" Basic Example of Html 5 cache")]),t._v(" "),e("p",[t._v("this is our index.html file")]),t._v(" "),e("div",{staticClass:"language-html extra-class"},[e("pre",{pre:!0,attrs:{class:"language-html"}},[e("code",[e("span",{pre:!0,attrs:{class:"token doctype"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("")])]),t._v("\n"),e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("<")]),t._v("html")]),t._v(" "),e("span",{pre:!0,attrs:{class:"token attr-name"}},[t._v("manifest")]),e("span",{pre:!0,attrs:{class:"token attr-value"}},[e("span",{pre:!0,attrs:{class:"token punctuation attr-equals"}},[t._v("=")]),e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v('"')]),t._v("index.appcache"),e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v('"')])]),e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v(">")])]),t._v("\n"),e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("<")]),t._v("body")]),e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v(">")])]),t._v("\n "),e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("<")]),t._v("p")]),e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v(">")])]),t._v("Content"),e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("")])]),t._v("\n"),e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("")])]),t._v("\n"),e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token tag"}},[e("span",{pre:!0,attrs:{class:"token punctuation"}},[t._v("")])]),t._v("\n\n")])])]),e("p",[t._v("then we will create index.appcache file with below codes")]),t._v(" "),e("div",{staticClass:"language-html extra-class"},[e("pre",{pre:!0,attrs:{class:"language-html"}},[e("code",[t._v("CACHE MANIFEST\nindex.html\n\n")])])]),e("p",[t._v("write those files that you want to be cached\nload index.html then go for offline mode and reload the tab")]),t._v(" "),e("p",[e("strong",[t._v("Note:")]),t._v(" The two files must be in the same folder in this example")]),t._v(" "),e("h4",{attrs:{id:"remarks"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#remarks"}},[t._v("#")]),t._v(" Remarks")]),t._v(" "),e("p",[t._v('The manifest file is a simple text file, which tells the browser what to cache (and what to never cache).\nThe recommended file extension for manifest files is: ".appcache"\nThe manifest file has three sections:')]),t._v(" "),e("p",[t._v("CACHE MANIFEST - Files listed under this header will be cached after they are downloaded for the first time")]),t._v(" "),e("p",[t._v("NETWORK - Files listed under this header require a connection to the server, and will never be cached")]),t._v(" "),e("p",[t._v("FALLBACK - Files listed under this header specifies fallback pages if a page is inaccessible")])])}),[],!1,null,null,null);a.default=n.exports}}]);