issues with jquery 1.4.1 - 1.7.x
issues with jquery 1.4.1 - 1.7.x
Hello,
I'm using "initComplete" for Individual column searching (select inputs). I get error in console:
dataTables.buttons.js:1640 Uncaught TypeError: $(...).on is not a function
at dataTables.buttons.js:1640
at dataTables.buttons.js:28
at dataTables.buttons.js:30
jquery.dataTables.js:4201 Uncaught TypeError: $(...).val(...).attr(...).on is not a function
at _fnFeatureHtmlFilter (jquery.dataTables.js:4201)
at _fnAddOptionsHtml (jquery.dataTables.js:3629)
at _fnInitialise (jquery.dataTables.js:4681)
at loadedInit (jquery.dataTables.js:1320)
at HTMLTableElement.<anonymous> (jquery.dataTables.js:1332)
at Function.each (jquery-1.4.1.js:572)
at init.each (jquery-1.4.1.js:240)
at init.DataTable [as dataTable] (jquery.dataTables.js:869)
at init.$.fn.DataTable (jquery.dataTables.js:15134)
at HTMLDocument.<anonymous> (index.html:66)
You can see code here.
If i use an earlier version of jquery eg. 1.12.4 or 1.8.1 i get no error and everything displays correctly. Do you know the cause of the problem?
Thanks in advance,
stelios
Replies
DataTables requires jQuery 1.7 or newer.
If you are having problems with 1.7, please link to a test case showing the issue.
Allan
Sorry - you did provide a link. It works with 1.7.1: https://jsfiddle.net/gy7z7bu5/1/ .
I'm not clear why you would use a very old version of jQuery though.
Allan
Well i think the problem is with on(), which was introduced in version 1.7.1, so maybe the only solution is to update jquery to 1.7.x
Thanks for your quick response,
stelios