jquery - How to add context menu to datatables 1.10? -


i'm using datatables (datatables.net) , add context menu table.

i found jquery contextmenu , description in datatables forum on how implemented context menu. seems @ least datatables i'm using (1.10) has evolved quite much. have not information context menu plugin. (meaning version using in forum post , have downloaded).

if use described in forum post , adapt 1.10 (to humble knowledge) i'm comming this

var mytable = $("#mytable ").datatable( {     "drawcallback": function( settings ) {         $("#mytable tbody tr").contextmenu(         {             menu: 'mymenu'},             function( action, el, pos ) {                 var adata = mytable.getdata( el.context );             }         );     } } ); 

but executing code give me error:

uncaught error: no selector specified in jquery.contextmenu.js:1273

has implementet context menu datatable 1.10?

i have see question, , answer because looking solution this.

here have demo using jquery.ui-contextmenu: demo

i use jquery.ui in addition, hope won't problem you.

it integrated functions fnfilter() , fnfilterclear(), can filter data using right-click.

thanks!

update: datatables 1.10 api style!

removed fnfilter() , fnfilterclear() , use new search() api method.

demo :)


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -