Add background to mobile viewport
Description
The following code shows how to add background to mobile viewport.
Example
<!DOCTYPE html>
<html>
<head>
<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.6.4.min.js"></script>
<script
src="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.js"></script>
<style type='text/css'>
.ui-mobile .ui-page {<!--from w w w. j av a 2 s. co m-->
background: transparent;
}
body.ui-mobile-viewport {
background: url(http://placehold.it/300x300);
}
</style>
</head>
<body>
<div id="page1" data-role="page">
<div data-role="header">
<h1>Page 1</h1>
</div>
<div data-role="content">
<a data-role="button" href="#page2">Forward</a>
</div>
</div>
<div id="page2" data-role="page">
<div data-role="header">
<h1>Page 2</h1>
</div>
<div data-role="content">
<a data-role="button" href="#page1">Back</a>
</div>
</div>
</body>
</html>