Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jQuery TableSorter Plugin(Uncaught TypeError: Cannot read property 'msie' of undefined)

i am using this plugin for pagination .this

i includes files in my header as follow:

<script src="<?php echo base_url('_assets/js/jQuery-2.1.3.min.js');?>"></script>
<script src="<?php echo base_url('_assets/js/tablesorter/jquery.tablesorter.js');?>" type="text/javascript"></script>
<script src="<?php echo base_url('_assets/js/tablesorter/addons/pager/jquery.tablesorter.pager.js');?>" type="text/javascript"></script>

my page script:

$(document).ready(function() {
     $("#p_history")
    .tablesorter({widthFixed: true, widgets: ['zebra']})
    .tablesorterPager({container: $("#pager")});
});

Error :Uncaught TypeError: Cannot read property 'msie' of undefined

Does anyone know the solution ?

like image 432
Abdul Manan Avatar asked Nov 18 '25 21:11

Abdul Manan


1 Answers

As i am seeing, you are using 2.0 jquery version, and probably tablesorter plugin working with old jquery version..

Error is occuring because $.browser.mise function has deprecated in jQuery 2.0 version, so you should use older jQuery version <= 1.3. Or use compatible sorter plunin.

like image 100
Girish Avatar answered Nov 21 '25 12:11

Girish