Creating a simple jQueryMobile app is not much different than creating a web site using Dreamweaver. There are only a few differences. All of the options except the last one below can be used to create a web-based jQueryMobile app. However, to create a real mobile app that can be sent to Google Play or Apple Store, the last option is needed:
While optional, creating a theme first has several advantages. Besides allowing you to create multiple themes and their necessary files and images, it also allows you to create an index.html page that has the necessary links to the jQueryMobile Framework that you can use as a starting point.
<div data-role="content">
<ul data-role="listview" data-inset="true">
<li><a href="#">
<h3>Dreamweaver</h3>
<p>Web and Mobile</p>
</a></li>
<li><a href="#">
<h3>Photoshop</h3>
<p>Imaging and Composite</p>
</a></li>
<li><a href="#">
<h3>Illustrator</h3>
<p>Vector and Illustrations</p>
</a></li>
<li><a href="#">
<h3>InDesign</h3>
<p>Layout and Print</p>
</a></li>
</ul>
</div>
<ul data-role="listview" data-inset="true">NOTE: In Dreamweaver's Design view, it should look like this:
<li><a href="#"><img src="../images/dw.jpg" width="99" height="99" alt=""/>
<h3>Dreamweaver</h3>
<p>Web and Mobile</p>
</a></li>
<li><a href="#"><img src="../images/ps.jpg" width="100" height="99" alt=""/>
<h3>Photoshop</h3>
<p>Imaging and Composite</p>
</a></li>
<li><a href="#"><img src="../images/ai.jpg" width="100" height="99" alt=""/>
<h3>Illustrator</h3>
<p>Vector and Illustrations</p>
</a></li>
<li><a href="#"><img src="../images/id.jpg" width="100" height="99" alt=""/>
<h3>InDesign</h3>
<p>Layout and Print</p>
</a></li>
</ul>
<ul data-role="listview" data-inset="true">
<li><a href="dw.html"><img src="../images/dw.jpg" width="99" height="99" alt=""/>
<h3>Dreamweaver</h3>
<p>Web and Mobile</p>
</a></li>
<li><a href="ps.html"><img src="../images/ps.jpg" width="100" height="99" alt=""/>
<h3>Photoshop</h3>
<p>Imaging and Composite</p>
</a></li>
<li><a href="ai.html"><img src="../images/ai.jpg" width="100" height="99" alt=""/>
<h3>Illustrator</h3>
<p>Vector and Illustrations</p>
</a></li>
<li><a href="id.html"><img src="../images/id.jpg" width="100" height="99" alt=""/>
<h3>InDesign</h3>
<p>Layout and Print</p>
</a></li>
</ul>
<ul data-role="listview" data-inset="true">
<li><a href="dw.html" data-ajax="false"><img src="../images/dw.jpg" width="99" height="99" alt=""/>
<h3>Dreamweaver</h3>
<p>Web and Mobile</p>
</a></li>
<li><a href="ps.html" data-ajax="false"><img src="../images/ps.jpg" width="100" height="99" alt=""/>
<h3>Photoshop</h3>
<p>Imaging and Composite</p>
</a></li>
<li><a href="ai.html" data-ajax="false"><img src="../images/ai.jpg" width="100" height="99" alt=""/>
<h3>Illustrator</h3>
<p>Vector and Illustrations</p>
</a></li>
<li><a href="id.html" data-ajax="false"><img src="../images/id.jpg" width="100" height="99" alt=""/>
<h3>InDesign</h3>
<p>Layout and Print</p>
</a></li>
</ul>
Linking within a multi-page document
A single HTML document can contain one or many 'page' containers simply by stacking multiple divs with a data-role of "page".
This allows you to build a small site or application within a single HTML document; jQuery Mobile will simply display
the first 'page' it finds in the source order when the page loads.
If a link in a multi-page document points to an anchor (#foo), the framework will look for a page wrapper with that ID (id="foo").
If it finds a page in the HTML document, it will transition the new page into view. You can seamlessly navigate between
local, internal "pages" and external pages in jQuery Mobile. Both will look the same to the end user except that external
pages will display the Ajax spinner while loading. In either situation, jQuery Mobile updates the page's URL hash to enable
Back button support, deep-linking and bookmarking.
It's important to note that if you are linking from a mobile page that was loaded via Ajax to a page that contains multiple
internal pages, you need to add a rel="external" or data-ajax="false" to the link. This tells the framework to do a full page
reload to clear out the Ajax hash in the URL. This is critical because Ajax pages use the hash (#) to track the Ajax
history, while multiple internal pages use the hash to indicate internal pages so there will be conflicts in the hash
between these two modes.
For example, a link to a page containing multiple internal pages would look like this: <a href="multipage.html" rel="external">Multi-page link</a>
<ul data-role="listview" data-inset="true">NOTE: Besides the data-theme, you can also add a data-divider-theme within the ul element.
<li data-role="list-divider">Adobe Applications:</li>
<li>...</li>
<li>...</li>
<li>...</li>
<li>...</li>
<li data-role="list-divider"> </li>
</ul>
While we can create a Dreamweaver template for the other pages, for simplicity sake, we will create them using the index.html page created earlier since there are only five pages total.
<div data-role="page" id="dw_page">
<div data-role="header">
<h1>Adobe Apps</h1>
</div>
<div data-role="content">
<h2>What's New in Dreamweaver </h2>
</div>
<div data-role="footer">
<h4>Copyright 2020 by RMCS. All rights reserved.</h4>
</div>
</div>
Currently, you will have to use the Back button on the browser to go back to the home page. This problem will be fixed in the steps below. A Home button needs to be created in the header so that a user can navigate back to the home page.
When you add one or more anchor element (e.g., <a>) to a header, they will automatically be converted to buttons and positioned to the far left of that header. It does not matter if you place the anchor element above or below the h3 element, they will still render to the left of the heading's text. However, for a screen reader user, it is best to have it above the h3 so that it can be read first.
<div data-role="header">
<a href="index.html" data-ajax="false">Home</a>
<h1>Adobe Apps</h1>
</div>
<div data-role="header">
<a href="index.html" data-ajax="false" data-icon="home">Home</a>
<h1>Adobe Apps</h1>
</div>
Since the other pages are similar the second page that was created, we can use it as a starting point.
A Control Group can be created so that a user can navigate to open another other page or a dialog.
Unlike when you add buttons to a header, when you add one or more anchor elements (<a>) to a footer, they will not automatically be converted to buttons. They will be links placed adjacent to each other and above or below the h4 element in the footer depending if they are placed above or below the h4 element.
Control group is as the name implies "a group of control elements" usually buttons. The advantage of "wrapping" a group of control element is to allow the group to have rounded corners at the top and bottom if they are vertical or right and left sides of the group if they are horizontal.
<div data-role="footer">NOTE: Notice in Design View that they are to the left and adjacent to each other as stated earlier.
<a href="about.html" data-ajax="false">About...</a>
<a href="summary.html" data-ajax="false">Summary</a>
</div>
<a href="about.html" data-ajax="false" class="ui-btn">About...</a>
<a href="summary.html" data-ajax="false" class="ui-btn">Summary</a>
<div data-role="controlgroup" data-type="horizontal">
<a href="about.html" data-ajax="false" class="ui-btn">About...</a>
<a href="summary.html" data-ajax="false" class="ui-btn">Summary</a>
</div>
<div data-role="controlgroup" data-type="horizontal" align="center">
Optional, you can create dialog boxes with transition effect applied to them.
<div data-role="page" id="about_page">summary.html:
<div data-role="header">
<a href="index.html" data-ajax="false" data-icon="home">Home</a>
<h1>Adobe Apps</h1>
</div>
<div data-role="content">
<h2>About This App</h2>
<p>The purpose of this app is to showcase how to create a mobile app using the
jQueryMobile Framework. jQuery Mobile framework takes the "write less, do more"
mantra to the next level: Instead of writing unique applications for each mobile
device or OS, the jQuery mobile framework allows you to design a single
highly-branded responsive web site or application that will work on all popular
smartphone, tablet, and desktop platforms.</p>
</div>
<div data-role="footer">
<h4>Copyright 2020 by RMCS. All rights reserved.</h4>
</div>
</div>
<div data-role="page" id="about_page" data-dialog="true">
<div data-role="header">
<div data-role="header">
<!-- <a href="index.html" data-ajax="false" data-icon="home">Home</a>-->
<div data-role="controlgroup" data-type="horizontal" align="center">
<a href="about.html" class="ui-btn" data-transition="slidedown">About...</a>
<a href="summary.html" class="ui-btn"data-transition="slidedown">Summary</a>
</div>
<a href="#popupjQueryMobile" data-rel="popup" data-transition="flow">jQueryMobile Framework</a>
<div data-role="popup" id="popupjQueryMobile" data-theme="a">NOTE: The div element is a wrapper for the tooltip with a role of popup an id of popupjQueryMobile and a data-theme of a. The a element is the Close button with a host of attributes and the p element is the tooltip itself with no attribute. The data-role = "popup" will initially HIDE the paragraph tag until the popup link is clicked.
<a href="#" data-rel="back" data-role="button" data-icon="delete" class="ui-btn-right" data-iconpos="notext">Close</a>
<p>jQuery Mobile is a HTML5-based user interface system designed to make responsive web sites and apps
that are accessible on all smartphone, tablet and desktop devices.</p>
</div>
</div>
</body>
</html>
<div data-role="content">
<h2>What's New in Dreamweaver</h2>
<div data-role="collapsible" data-inset="true">
<h3>Menu Item 1</h3>
<p>Menu Item 1 content here...</p>
</div>
<div data-role="collapsible" data-inset="true">
<h3>Menu Item 2</h3>
<p>Menu Item 2 content here...</p>
</div>
<div data-role="collapsible" data-inset="true">
<h3>Menu Item 3</h3>
<p>Menu Item 3 content here...</p>
</div>
</div>
<div data-role="content">
<h2>What's New in Dreamweaver</h2>
<div data-role="collapsible" data-inset="true" data-collapsed-icon="carat-r" data-expanded-icon="carat-d">
<h3>Menu Item 1</h3>
<p>Menu Item 1 content here...</p>
</div>
<div data-role="collapsible" data-inset="true" data-collapsed-icon="carat-r" data-expanded-icon="carat-d">
<h3>Menu Item 2</h3>
<p>Menu Item 2 content here...</p>
</div>
<div data-role="collapsible" data-inset="true" data-collapsed-icon="carat-r" data-expanded-icon="carat-d">
<h3>Menu Item 3</h3>
<p>Menu Item 3 content here...</p>
</div>
</div>
<style>
img{width:100%;height:auto;}
</style>
<ul data-inset="true" data-role="listview" >
<li data-role="list-divider">Adobe Apps</li>
<li><a href="dw.html" data-ajax="false">
<img src="images/dw.jpg" width="99" height="99" alt=""/>
<span class="ui-li-count">3</span>
<h3>Dreamweaver</h3>
<p>Web and Mobile</p>
</a></li>
<li><a href="ps.html" data-ajax="false">
<img src="images/ps.jpg" width="100" height="99" alt=""/>
<span class="ui-li-count">7</span>
<h3>Photoshop</h3>
<p>Imaging and Composite</p>
</a></li>
<li><a href="ai.html" data-ajax="false">
<img src="images/ai.jpg" width="100" height="99" alt=""/>
<span class="ui-li-count">8</span>
<h3>Illustrator</h3>
<p>Vector and Illustration</p>
</a></li>
<li><a href="id.html" data-ajax="false">
<img src="images/id.jpg" width="100" height="99" alt=""/>
<span class="ui-li-count">13</span>
<h3>InDesign</h3>
<p>Layout and Print</p>
</a></li>
<li data-role="list-divider"> </li>
</ul>
Another way to create a mobile app is to use a Single Page Application (SPA) method. In this method ALL of the pages are within a SINGLE PAGE. It is important to note that all href references are INTERNAL (e.g., # home_page, #dw_page, etc) instead of EXTERNAL (e.g., index.html, dw.html, etc.)
<li><a href="#dw_page" data-ajax="false">
<img src="images/dw.jpg" width="99" height="99" alt=""/>
<span class="ui-li-count">3</span>
<h3>Dreamweaver</h3>
<p>Web and Mobile</p>
</a></li>
<div data-role="header">
<a href="#home_page" data-ajax="false" data-icon="home">Home</a>
<h1>Adobe 2020</h1>
</div>
Download Example: CompletedApp
View Demo: Adobe CC App
Download Adobe Apps Icons: AdobeApps_Icons.zip
Download Example: CompletedApp2
View Demo: ForeignWordsInEnglish App
Download Example: IdiomsDictionary/CompletedApp3
View Demo: IdiomsDictionary