Server IP : 108.170.25.35 / Your IP : 18.226.187.60 Web Server : Apache/2 System : Linux gains.winzonesoftech.com 4.18.0-513.24.1.el8_9.x86_64 #1 SMP Mon Apr 8 11:23:13 EDT 2024 x86_64 User : studio ( 1434) PHP Version : 8.1.28 Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /home/studio/public_html/gfgdfgdfg/js/plugins-init/ |
Upload File : |
(function($) { "use strict" var table = $('#example-api-1').DataTable(); // Apply the search table.columns().every( function () { var that = this; $( 'input', this.footer() ).on( 'keyup change', function () { if ( that.search() !== this.value ) { that .search( this.value ) .draw(); } }); }); $('#example-api-2').DataTable( { initComplete: function () { this.api().columns().every( function () { var column = this; var select = $('<select><option value=""></option></select>') .appendTo( $(column.footer()).empty() ) .on( 'change', function () { var val = $.fn.dataTable.util.escapeRegex( $(this).val() ); column .search( val ? '^'+val+'$' : '', true, false ) .draw(); } ); column.data().unique().sort().each( function ( d, j ) { select.append( '<option value="'+d+'">'+d+'</option>' ) } ); } ); } } ); //Row selection (multiple rows) var table = $('#example-api-3').DataTable(); $('#example-api-3 tbody').on( 'click', 'tr', function () { $(this).toggleClass('selected'); } ); $('#show-row').click( function () { alert( table.rows('.selected').data().length +' row(s) selected' ); } ); //Add new row var t = $('#example-api-4').DataTable(); var counter = 1; $('#addRow').on( 'click', function () { t.row.add( [ counter +'.1', counter +'.2', counter +'.3', counter +'.4', counter +'.5' ] ).draw( false ); counter++; } ); // Automatically add a first row of data $('#addRow').click(); //Form inputs var table = $('#example-api-5').DataTable(); $('#form-submit').click( function() { var data = table.$('input, select').serialize(); alert( "The following data would have been submitted to the server: \n\n"+ data.substr( 0, 120 )+'...' ); return false; }); //Show / hide columns dynamically var table = $('#example-api-6').DataTable( { "scrollY": "200px", "paging": false } ); $('.toggle-vis').on( 'click', function (e) { e.preventDefault(); // Get the column API object var column = table.column( $(this).attr('data-column') ); // Toggle the visibility column.visible( ! column.visible() ); }); //Search API (regular expressions) function filterGlobal () { $('#example-api-7').DataTable().search( $('#global_filter').val(), $('#global_regex').prop('checked'), $('#global_smart').prop('checked') ).draw(); } function filterColumn ( i ) { $('#example-api-7').DataTable().column( i ).search( $('#col'+i+'_filter').val(), $('#col'+i+'_regex').prop('checked'), $('#col'+i+'_smart').prop('checked') ).draw(); } $('#example-api-7').DataTable(); $('input.global_filter').on( 'keyup click', function () { filterGlobal(); } ); $('input.column_filter').on( 'keyup click', function () { filterColumn( $(this).parents('tr').attr('data-column') ); }); })(jQuery);