<!DOCTYPE html>
<html>
<head>
<title>Meine erste App</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.css" />
<script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script src="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.js"></script>
<script type="text/javascript">
$("#randomButton").live("click", function() {
var items = new Array ("Text 1",
"Text 2",
"Text 3",
"Text 4",
"Text 5",
"Text 6",
"Text 7",
"Text 8",
"Text 9",
"Text 10");
var item = items[Math.floor(Math.random()*items.length)];
$("#ramdomItemText").text(item);
$.mobile.changePage($("#randomItemDialog"));
});
</script>
<script type="text/javascript" charset="utf-8" src="cordova-1.9.0.js"></script>
</head>
<body>
<div data-role="page">
<div data-role="header">
<h1>Meine erste App</h1>
</div><!-- /header -->
<div data-role="content">
<p><a href="" id="randomButton" data-role="button" data-inline="true">Klick mich an!</a></p>
</div><!-- /content -->
</div><!-- /page -->
<div data-role="dialog" id="randomItemDialog">
<div data-role="header">
<h1>Meine erste App</h1>
</div>
<div data-role="content">
<p id="ramdomItemText"></p>
<p><a href="" data-role="button" data-rel="back">Cool, danke</a></p>
</div>
</div>
</body>
</html>