Book Image

jQuery Mobile Web Development Essentials-Third Edition - Third Edition

By : Raymond Camden, Andy Matthews
Book Image

jQuery Mobile Web Development Essentials-Third Edition - Third Edition

By: Raymond Camden, Andy Matthews

Overview of this book

jQuery Mobile is a HTML5-based touch-optimized web framework. jQuery Mobile can be used to build responsive cross-platform websites and apps for a wide range of smartphones, tablets, and desktop devices. The jQuery Mobile framework can be integrated with other mobile app frameworks such as PhoneGap, IBM Worklight, and more. Introduction to jQuery Mobile explains how to add the framework to your HTML pages to create rich, mobile-optimized web pages with minimal effort. You’ll learn how to use jQuery Mobile’s automatic enhancements and configure the framework for customized, powerful mobile-friendly websites. We then dig into forms, events, and styling. You'll see how jQuery Mobile automatically enhances content, and will find out how to use the JavaScript API to build complex sites. We’ll introduce you to how jQuery Mobile can be themed as well looking into how JavaScript can be used for deep sets of customizations. The examples are ready to run and can be used to help kick-start your own site. Along the way, you will leverage all the concepts you learn to build three sample mobile applications.
Table of Contents (20 chapters)
jQuery Mobile Web Development Essentials Third Edition
Credits
About the Authors
About the Reviewer
www.PacktPub.com
Preface
Index

Creating the RSS reader application


Our application begins with the first page, index.html. This page will load in jQuery and jQuery Mobile as well. Its core mission is to list your current feeds, but it has to recognize when the user has no feeds at all and provide a bit of text encouraging them to add their first feed:

Code 13-1: index.html
<!DOCTYPE html>
<html>
<head>
<title>RSS Reader App</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" 
   href="jquery.mobile/jquery.mobile-1.4.5.min.css" />
<script src="jquery.mobile/jquery-2.1.3.min.js"></script>
<script src="jquery.mobile/jquery.mobile-1.4.5.min.js"></script>
<script src="main.js"></script>
</head>

<body>

<div data-role="page" id="intropage">

   <div data-role="header">
         <h1>RSS Reader Application</h1>
   </div>
   
   <div role="main" class="ui-content...