用户向下滚动到页面底部后,导航回页面顶部不起作用。
页脚
<div data-role="footer" data-theme="b">
<div class="ui-bar">
<a href="" data-role="button" data-icon="arrow-u" data-theme="d" style="float:right;" class="returnTopAction">Return top</a>
</div>
</div>
jQuery 参考
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.css" />
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script src="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.js"></script>
更新: 我的完整 HTML 代码
<html>
<head>
<title>SQ/TR</title>
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.css" />
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script src="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.js"></script>
</head>
<body>
<div data-role="page" id="arealistpage">
<div data-role="header" data-theme="b">
<h1>SQ/TR</h1>
<a href="../Default.aspx" class='ui-btn-left ui-btn-back' data-icon='arrow-l'>Back</a>
</div>
<!-- /header -->
<div data-role="content">
<ul data-filter="true" data-inset="true" data-role="listview">
<li>
<a href="#">Design Squad Check</a>
</li>
<li>
<a href="#">Vendor Squad Check</a>
</li>
<li>
<a href="#">Business Squad Check</a>
</li>
<li>
<a href="#">Management Squad Check</a>
</li>
<li>
<a href="#">Design Transmittal</a>
</li>
<li>
<a href="#">Vendor Transmittal</a>
</li>
<li>
<a href="#">Business Transmittal</a>
</li>
<li>
<a href="#">Management Transmittal</a>
</li>
</ul>
</div>
<!-- /content -->
<div data-role="footer" data-theme="b" id="footerNavBar">
<div class="ui-bar">
<a href="" data-role="button" data-icon="arrow-u" data-theme="d" style="float:right;" class="returnTopAction">Return top</a>
</div>
</div>
</div>
<!-- /page -->
</body>
</html>