Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

4. Creating Multipage Websites > Single-Page Template

Single-Page Template

Single-page templates are separate HTML files that act as independent webpages, just like any standard webpage. The main difference is in how jQuery Mobile connects webpages using Ajax. As with multipage templates, the Ajax-based navigation in single-page templates uses hashtags to create a page history. The Ajax-based navigation used by jQuery Mobile is the default, but it can be turned off by setting the ajaxEnabled setting to false in the configuration. You’ll learn more about the configuration settings later in this book.

Ajah is an abbreviation that is sometimes used for Asynchronous JavaScript and HTML. Ajah is essentially Ajax without the XML; the XMLHttpRequest is still used, but HTML is exchanged with the server rather than XML. This is what jQuery Mobile uses as the user browses independent webpages. We briefly covered how the jQuery Mobile framework uses the XMLHttpRequest to load subsequent pages in the previous chapter, but there’s a lot to learn and understand about this simple request.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free 10-Day Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint