Search
10784 results 2531-2540
Forum
- 9th Mar 2012associating a form with a table when initializing multiple dataTablesSo far as I can determine, what appears to be happening is that the first table gets a TableTools object on dataTable initialization. But subsequent tables do not get a TableTools object. I've overcome this by wrapping the initialization in an .each(), like so: [code] $(document).ready(function(){ $('.dtg').each(function(){ $(this).dataTable({ "bJQueryUI": true, "bProcessing": true, "bStateSave": true, "sDom": '<"H">tr<"F"T>', 'sScrollX':'100%', "oTableTools": { "sRowSelect": "single", "sSwfPath": "media/swf/copy_cvs_xls_pdf.swf", "aButtons": [],// no buttons "fnRowSelected": function(node){ var table = $(node).parents('table'); aData = $(table).dataTable().fnGetData(node); context = $(table).parents('div.fs'); $('input[name="col1"]',$(context)).val(aData[0]); $('input[name="col2"]',$(context)).val(aData[1]); }, "fnRowDeselected": function(node){ var table = $(node).parents('table'); aData = $(table).dataTable().fnGetData(node); context = $(node).closest('div.fs'); $('input[name="col1"]',$(context)).val(undefined); $('input[name="col2"]',$(context)).val(undefined); } } }); }) }); [/code]
- 11th Jan 2012sDom not initializingOkay, just got this figured out. If anyone else is running into this issue, it helps to use the index files and make sure you have the correct .js files linked. It gets a little confusing with the media/js/ColReorder as those file locations are similar for demos vs the actual .js files to link to. Still love this tool as I think is well above and beyond anything else I have tried to work with, just a step by step how-to would be helpful. Maybe as a user group that should be an effort we establish if it hasn't already been started.
- 5th Dec 2011How to set up Jeditable in edit mode initially?Sorry lost track of this. on the Jeditable website, in order to set it in edit mode initally. I was told: You can trigger the used event when your document loads. For example: $(function() { $("#editable").trigger("click"); Not sure how to access this trigger event on Datatables? Any help?
- 28th Nov 2011Ajax source and aaData initialisation parameter - width of columns different after second callAh... I had set an inline style on the tables, but it was getting destroyed on the second call and replaced with the attribute "style='width: 100px'". Putting the style in a stylesheet and marking !important clears it up. Thanks!
- 26th Sep 2011Initializing dataTables with no records to display at firsthttp://www.datatables.net/ref#iDeferLoading
- 5th Sep 2011Unexpected initialization return value when initialising inside an ObjectNevermind. This was because the selector name for the table is wrong.
- 17th Aug 2011All row displaying on initialisationHey allan, Ye, its 26. I understand what i need to do now, thanks. The processing of the rows needs to be done on initialization when using serverSide and ajaxSource and not just when filtering, sorting etc.
- 19th Jul 2011Row Details InitialShould I modify some details in source code?
- 9th Feb 2011bug on initial sort when using title-numeric plug-inSolved. Silly mistake, need to make sure the plug-in is defined before table initialization (duh).
- 22nd Nov 2010Manualy initialising datatableshttp://datatables.net/usage/callbacks#fnServerData - as shown you can construct your own Ajax call to the server. So all you need to do is add an if cndition in there to say that if it's the first draw just give the callback method an empty data set. Otherwise, do the Ajax call to the server. Allan