Append collapsible to page
Description
The following code shows how to append collapsible to page.
Example
<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'
src='http://code.jquery.com/jquery-1.4.4.min.js'></script>
<script type='text/javascript'
src="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.js"></script>
<link rel="stylesheet" type="text/css"
href="http://code.jquery.com/mobile/1.0a2/jquery.mobile-1.0a2.min.css">
<script type='text/javascript'>
$(window).load(function(){<!-- ww w . j a va 2s. c om-->
$('<div data-role="collapsible"><h3>Title</h3><p>Content</p></div>').appendTo('[data-role="content"]').page()
});
</script>
</head>
<body>
<div data-role="page" data-theme="b" id="page">
<div data-role="content">
<div data-role="collapsible">
<h3>I'm a header</h3>
<p>I'm the collapsible content. </p>
</div>
</div>
</div>
</body>
</html>