0
我正在使用creating a table
表格使用jTable plugin
。我試圖用PHP來實現它。我下載了示例文件,它工作得很好。jTable Head Section Files
問題是:當我執行代碼表時,沒有"go to page area"
。 我試着解決了在客戶端代碼中更改Html頭部文件的問題。所以我下載了最新版本的jquery,jquery-ui和jtable。 我不確定問題出在客戶端代碼還是文件Jquery,jquery-ui它尊重我下載的.css和.js文件。
這是我的代碼:
<html>
<head>
<link rel="stylesheet" href="jquery-ui-1.11.2/jquery-ui.css" />
<link href="Scripts/jtable/themes/lightcolor/blue/jtable.css" rel="stylesheet" type="text/css" />
<script src="scripts/jquery-1.11.1.js"></script>
<script src="scripts/jquery-ui-1.8.16.custom.min.js"></script>
<script src="Scripts/jtable/jquery.jtable.js" type="text/javascript"></script>
</head>
<body>
<div id="PeopleTableContainer" style="width: 600px;"></div>
<script type="text/javascript">
$(document).ready(function() {
//Prepare jTable
$('#PeopleTableContainer').jtable({
title: 'Table of people',
paging: true,
pageSize: 2,
gotoPageArea: 'combobox',
pageSizes: {10,25,50,100,250,500},
pageSizeChangeArea: true,
sorting: true,
defaultSorting: 'Name ASC',
actions: {
listAction: 'PersonActionsPagedSorted.php?action=list',
createAction: 'PersonActionsPagedSorted.php?action=create',
updateAction: 'PersonActionsPagedSorted.php?action=update',
deleteAction: 'PersonActionsPagedSorted.php?action=delete'
},
fields: {
PersonId: {
key: true,
create: false,
edit: false,
list: false
},
Name: {
title: 'Author Name',
width: '40%'
},
Age: {
title: 'Age',
width: '20%'
},
RecordDate: {
title: 'Record date',
width: '30%',
type: 'date',
create: false,
edit: false
}
}
});
//Load person list from server
$('#PeopleTableContainer').jtable('load');
});
</script>
</body>
</html>