25.02.2013 Views

Peter Lubbers - Pro HTML 5 Programming

Pro HTML 5 Programming

Pro HTML 5 Programming

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

CHAPTER 10 ■ CREATING <strong>HTML</strong>5 OFFLINE WEB APPLICATIONS<br />

Figure 10-3 shows the example application running in offline mode in Firefox. The example files for this<br />

application are located at the book web site in the 'Offline' section.<br />

Figure 10-3. The application in action in offline mode<br />

Creating a Manifest File for the Application Resources<br />

First, create the tracker.manifest file as follows. This will list the files that are part of this application:<br />

CACHE MANIFEST<br />

# JavaScript<br />

./offline.js<br />

#./tracker.js<br />

./log.js<br />

# stylesheets<br />

./html5.css<br />

# images<br />

251

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!