Search
19115 results 14101-14110
Forum
- 21st Jul 2017Search filter created in my doesn't work when datatables plugin is usedPerhaps you could link to the page showing what you are currently working on please? If you built your own external search, how are you telling DataTables to update what it draws? That is fundamental to how the export also works. Allan
- 5th Jan 2017Urgent Using Colvis with save state and indiviual column search on top creates issue.?i got a solution here is my solution $('#example').on('column-visibility.dt', function (e, settings, column, state) { if (state === true) { registerEventListener(); } }); function registerEventListener() { table.columns().every(function (index) { $('input ', this.footer()).off().on('keyup change', function () { table.columns($(this).parent().index() + ':visible') .search(this.value) .draw(); }); }); } registerEventListener();
- 12th Jul 2016How can I dynamically set background to rows After the table has been created?I would recommend using the callback function to paint the rows red. Please have a look. function myCallback() { var api = $('#table').DataTable(); //loop via all rows , check id and apply the css api.$('tr').each( function (i) { var _id = $(row).attr('id'); if( _id == 8 ) $(td).css('background-color','red'); }); };
- 8th Jul 2016DataTable().destroy() failed when the datatable is created with multiple buttonsSee this thread also from today which also discussed this issue. Allan
- 23rd Feb 2016Is it possible to show a spinner while a pdf is created with pdfhtml5Cool - hope that gets merged in :-) Allan
- 3rd Dec 2015How can I set the default field value while hiding it from create/update dialog?Found : field type 'hidden'. Please update docs.
- 13th Aug 2015Question about sorting columns with Editor created entriesHi, Are you using server-side processing? The reason I ask that is that the while space should make no difference with client-side processing. The > however, is sorted higher than [a-zA-Z] since it is lower in ASCII value than the letters even with client-side processing. If you wanted a different sort applied you would need to use a custom sorting plug-in if client-side, or modify the server-side script if server-side (typically that might need some kind of change to the database since it is that which will be providing the sort). Allan
- 4th Aug 2015Help with adding a link to a AJAX created datatableThank you very much. This is what I did. Hopefully it is correct. ''' jQuery(document).ready(function() { var selected_table = $('#selected_items').dataTable({ "ajax": '/cfcs/db_items.cfc?method=getSelectedItems&pid=34', "columnDefs": [{ "targets": 2, "render": function ( data, type, row, meta ) { var itemID = row[0]; return '<a href="/cfcs/blah.cfc?item_id=' + itemID + '">' + data + '</a>'; } }], "columns": [{ "visible": false, "orderable": false, },{ "orderable": true }, { "orderable": true }, { "orderable": true }, { "orderable": true }], "paging": false, "info": false, "searching": false }); }); '''
- 21st Apr 2015Is there a "post save" callback after Editor creates an entry into the databaseAgreed - I think that is something that I will look at adding for 1.5. Regards, Allan
- 16th Mar 2015changing row colour after editor create/editThe other option is to modify the row in the postEdit event. Unfortunately DataTables doesn't currently have a rowUpdated call back or event itself. That is something I will be adding in future (likely 1.11). Allan