时间:2021-07-01 10:21:17 帮助过:37人阅读
HTML代码:
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title>列车时刻表查询</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css" />
<script src="http://code.jquery.com/jquery-1.11.1.min.js"></script>
<script src="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>
</head>
<script src="js/connect.js"></script>
<body onload="init()">
<p data-role="page" id="pageone">
<p data-role="header" data-position="fixed">
<h1>列车时刻表查询</h1>
</p>
<p data-role="main" class="ui-content">
<p align="center">请给我留言</p>
<table data-role="table" class="ui-responsive">
<thead>
<tr>
<th>姓名:</th>
<th>留言:</th>
</tr>
</thead>
<tbody>
<tr>
<td><input type="text" id="name"></td>
<td><input type="text" id="memo"></td>
</tr>
</tbody>
</table>
<button type="submit" onclick="saveData()">留言</button>
<table data-role="table" data-mode="" class="ui-responsive" id="datatable">
<!--这里是留言板的显示区域-->
</table>
</p>
<!--
作者:ceet@vip.qq.com
时间:2017-08-26
描述:底部TAB
-->
<p data-role="footer" data-position="fixed">
<p data-role="navbar">
<ul>
<li>
<a href="index.html#index" data-icon="grid" class="ui-btn-active">查询</a>
</li>
<li>
<a href="index.html#detail" data-rel="popup" data-icon="star">收藏</a>
</li>
<li>
<a href="test.html" data-icon="comment">给我留言</a>
</li>
</ul>
</p>
</p>
<!--收藏功能-->
<p data-role="popup" id="myPopup" class="ui-content" data-theme="b">
<a href="#" data-rel="back" class="ui-btn ui-btn-a ui-corner-all ui-shadow ui-btn ui-icon-delete ui-btn-icon-notext ui-btn-right">Close</a>
<p>收藏成功,暂且不做处理!.</p>
<p>请点击右上角有个关闭按钮</p>
<p><b>提示:</b> 你也可以点击弹窗的外部区域来关闭弹窗。</p>
</p>
</p>
</body>
</html>JS代码:
我们有两个方法来进行软件设计:一个是让其足够的简单以至于让BUG无法藏身;另一个就是让其足够的复杂,让人找不到BUG。前者更难一些。
以上就是详解HTML5如何操作WebSQL数据库的详细内容,更多请关注Gxl网其它相关文章!