DataTables warning : Requested unknown parameter '5' from the data source for row 0
在该项目中我使用了jquery.dataTables.js来作为我的前端数据表格。
表格的官网地址:https://www.datatables.net/
一、jsp部分代码片段如下:
<table id="dynamic-table"
class="table table-striped table-bordered table-hover">
<thead>
<tr>
<th class="center"><label class="pos-rel"> <input
type="checkbox" class="ace" /> <span class="lbl"></span>
</label></th>
<th>文件名称</th>
<th>日期</th>
<th>绝对路径</th>
<th>操作</th>
<!-- <th style="display: none">绝对路径</th> -->
</tr>
</thead> <tbody>
<c:forEach items="${fileList}" var="file">
<tr>
<td class="center"><label class="pos-rel"> <input
type="checkbox" class="ace" /> <span class="lbl"></span>
</label></td>
<td>${file.name }</td>
<td>${file.date }</td>
<td>${file.path }</td>
<td>
<div class="hidden-sm hidden-xs action-buttons">
<a class="red" href="#"> <i
class="ace-icon fa fa-trash-o bigger-130"></i>
</a>
</div>
</td>
</tr>
</c:forEach>
</tbody>
</table>
二、js代码片段如下:
var oTable1 = $('#dynamic-table')
.dataTable({
bAutoWidth : false,
"aoColumns" : [ {
"bSortable" : false
}, null, null,null, null, {
"bSortable" : false
} ],
"aaSorting" : [],
});
三、运行的时候收到如下警告信息:
DataTables warning : Requested unknown parameter '' from the data source for row
四、原因分析
html写了页面有5列数据,而js代码里定义了6列数据。
五、解决办法
在我的环境中,删除js中的一个null列,问题就解决了。
DataTables warning : Requested unknown parameter '5' from the data source for row 0的更多相关文章
- DataTables warning : Requested unknown parameter '0' from the data source for row 0错误
在做datatables的项目,从后台取得数据后,返回给datatables界面时会报下面的错误: DataTables warning : Requested unknown parameter ' ...
- DataTables warning requested unknown parameter
This is possibly the most cryptic warning message that DataTables will show. It is a short error mes ...
- Jquery DataTables warning : Requested unknown from the data source for row 0
昨天在做 Jquery DataTables 的时候,遇到的一个问题,我使用MVC,在tables上加入了一个actionlink的href.但是在运行起来的时候,报错: DataTables war ...
- DataTables warning (table id = 'myTable'): Requested unknown parameter '0' from the data source for row 0
第一种方式:不用在js里设置列Html: <table id="myTable"> <thead> <tr> <th>Title-1 ...
- DataTables warning: table id=data-table - Requested unknown parameter '3' for row 0.
本文为博主原创,未经允许,不得转载: 在使用jquery 的datatable时,报错在页面弹出弹出框,并提示以下内容: DataTables warning: table id=data-table ...
- DataTables warning: table id=dataTable - Requested unknown parameter 'acceptId' for row 0. For more
重点内容 DataTables warning: table id=dataTable - Requested unknown parameter 'acceptId' for row 0. For ...
- DataTables warning: table id=DataTables_Table_0 - Requested unknown parameter '1' for row 0. For more information about this error, please see http://datatables.net/tn/4
今天在做后台的时候,考虑到会员模块和订单模块列表显示差不多,于是乎,偷了个懒,把会员列表显示页面的代码拷贝了过来,修改了一下,变成了订单模块.可是,在订单列表显示的时候老是报下面的错误,截图如下: 后 ...
- Warning: in_array() expects parameter 2 to be array, string given in D:\wamp\www\suiji.php on line 26
可参考上篇文章 链接 PHP数组简写模式 同样是PHP版本问题:in_array()函数 第二个参数应该为数组 但是 lnmp下,PHP5.3不报错,wamp下PHP5.5报以下错误: echo & ...
- Unknown parameter datatype UNKNOW send from server.
procedure Tmainform.Button7Click(Sender: TObject); begin kbmMWClientQuery3.Query.Text:='insert into ...
随机推荐
- zw版_zw中文增强版Halcon官方Delphi例程
[<zw版·delphi与halcon系列原创教程>zw版_zw中文增强版Halcon官方Delphi例程 源码下载:http://files.cnblogs.com/files/ziwa ...
- python 三元运算符
print (1==2) and 12 or 4 b=12 if 1==2 else 4print(b)
- AC68U 内Linux 终端前后的切换,终端挂起和恢复
ssh 登录终端后, 如果想切换到本地上来, 可以按: -,Ctrl+Z 如果要恢复到远程端,则命令: fg
- lamp环境编译(实际通过)
CentOS:5.5Apache:2.2.9PHP:5.2.6MySQL:5.0.41 条件: yum install gccyum install gcc-c++ vi/etc/yum.repos. ...
- scala 隐式转换
先参考这篇文章:http://www.jianshu.com/p/a344914de895 package com.test.scalaw.test /** * scala隐式转换 */ object ...
- HttpWebRequest:百度定位当前位置解析
HttpWebRequest request = (System.Net.HttpWebRequest)WebRequest.Create("http://api.map.baidu.com ...
- printf,sprintf,vsprintf 区别【转】
转自:http://blog.csdn.net/anye3000/article/details/6593551 有C语言写作历史的程序员往往特别喜欢printf 函数.即使可以使用更简单的命令(例如 ...
- View Properties [AX 2012]
View Properties [AX 2012] Other Versions This topic has not yet been rated - Rate this topic Updated ...
- 源码安装Apache,报错:Cannot use an external APR with the bundled APR-util和httpd: Could not reliably determine the server's fully qualified domain name, using
一.解决APR和APR-util错误: 1.1.安装APR: [root@ganglia httpd-2.2.23]# cd srclib/apr [root@ganglia apr]# ./conf ...
- PHP操作Memcache基本函数的方法
Memcache基本函数. Memcache ― Memcache类 Memcache::add ― 增加一个条目到缓存服务器 Memcache::addServer ― 向连接池中添加一个memca ...