日期:2014-05-16 浏览次数:20718 次
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<link href="css/jquery-ui-1.8.2.custom.css" rel="stylesheet" type="text/css" />
<link href="css/ui.jqgrid.css" rel="stylesheet" type="text/css" />
<script src="js/jquery.js" type="text/javascript"> </script>
<script src="js/i18n/grid.locale-en.js" type="text/javascript"></script>
<script src="js/jquery.jqGrid.min.js" type="text/javascript"> </script>
<script type="text/javascript">
$(document).ready(function () {
$("#list4").jqGrid({
url: "read.ashx",
datatype: "json",
editurl: "save.ashx",//////保存路径
mtype: 'get',
height: 300,
colNames: ['编号', '姓名', '日期', '地点'],
autowidth: false, //自动设置宽度
rownumbers: true,
closeAfterSearch: true,
colModel: [{ name: "id", index: "id", sorttype: "int", width: 60, editable: false, search: true },
{ name: "xm", index: "xm", sorttype: "text", width: 100, search: true, editable: true },
{ name: "rq", index: "rq", sorttype: "text", width: 100, editable: true, search: true },
{ name: "dd", index: "dd", sorttype: "text", width: 150, editable: true, search: true }
],
sortname: 'ID',
sortorder: "asc",
viewrecords: true,
rowNum: 10,
rowList: [10, 20, 30],
pager: '#pager', pgbuttons: false, pginput: false, pgtext: false,
&nb