In this tutorial we will learn how to develop a simple JQuery Mobile Web Application.

To begin, add links to Jquery Javascript.

<script src=”http://code.jquery.com/jquery-1.7.1.min.js”></script>
<script src=”http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.js”>

If you have written your own javascripts, make sure you include the script before the above 2 statements.

Having added the scripts, create a blank page using

<div data-role=”page” id=”pg1″>

</div>

Add a header,content and footer to this page,

<div data-role=”header”>
<h1>
HEADER</h1>
</div>

<div data-role=”content”>
<h1>
HELLO WORLD !</h1>
</div>

<div data-role=”footer”>
<h1>
FOOTER</h1>
</div>

and that’s it, our HELLO WORLD JQuery web app is ready !

DEMO

Complete code is given below

<!DOCTYPE html>
<html>

<head>
<title>Hello World !</title>
<link rel=”stylesheet” href=”http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.css” />
<script src=”http://code.jquery.com/jquery-1.7.1.min.js”></script>
<script src=”http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.js”></script>
</head>

<body>

<div data-role=”page” id=”pg1″>
<div data-role=”header”>
<h1>
HEADER</h1>
</div>

<div data-role=”content”>
<p> Hello world !</p>

</div>

<div data-role=”footer”>
<h1>
FOOTER</h1>
</div>


</div>

</body>
</html>