Manifest file is simple text file tells browser what to cache - HTML

Q.  A simple text file which tells the browser what to cache is known as a ________.
- Published on 28 Aug 15

a. Input files
b. HTML file
c. A manifest file
d. Output files

ANSWER: A manifest file
 

    Discussion

  • Nirja Shah   -Posted on 06 Nov 15
    Manifest File
    - It is a simple text file, which tells the browser what to cache (and what to never cache).

    - This file has three sections:

    1. CACHE MANIFEST
    - Files listed under this header will be cached after they are downloaded for the first time
    - The first line of this file is required:

    CACHE MANIFEST
    /theme.css
    /logo.gif
    /main.js

    - This file lists three resources: a CSS file, a GIF image, and a JavaScript file.
    - When this file is loaded, the browser will download the three files from the root directory of the web site.
    - Whenever the user is not connected to the internet, the resources will still be available.

    2. NETWORK
    - Files listed under this header require a connection to the server, and will never be cached
    - It specifies that the file "login.asp" should never be cached, and will not be available offline:

    NETWORK:
    login.asp
    - An asterisk is used to indicate that all other resources/files require an internet connection:

    NETWORK:
    *

    3. FALLBACK
    - The files listed under this header specifies fallback pages if a page is inaccessible

    - It specifies that "offline.html" will be served in place of all files in the /html/ catalog, in case an internet connection cannot be established:
    FALLBACK:
    /html/ /offline.html

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)