Reputation: 11265
I'm getting this error:
Uncaught TypeError: Cannot read property 'fnInit' of undefined
jquery.dataTables.js:2872
DataTable.ext.oPagination[ oSettings.sPaginationType ].fnInit( oSettings, nPaginate,
function( oSettings ) {
_fnCalculateEnd( oSettings );
_fnDraw( oSettings );
}
);
Table is placed properly, I think, that problem is not in HTML.
Upvotes: 13
Views: 18347
Reputation: 58880
It seems that the problem is that you used not supported value for sPaginationType
or pagingType
option.
DataTables 1.10
Option pagingType
supports the following values by default:
numbers
- Page number buttons only (1.10.8+)simple
- 'Previous' and 'Next' buttons onlysimple_numbers
- 'Previous' and 'Next' buttons, plus page numbersfull
- 'First', 'Previous', 'Next' and 'Last' buttonsfull_numbers
- 'First', 'Previous', 'Next' and 'Last' buttons, plus page numbersDataTables 1.9
Option sPaginationType
supports the following values by default:
two_button
- 'Previous' and 'Next'full_numbers
- 'First', 'Previous', 'Next' and 'Last' buttons, plus page numbersUpvotes: 36