Search
19098 results 631-640
Forum
- 8th Aug 2016Create Json from selected row data of JsonThanks.. This is what i want
- 9th Jun 2016Dynamically Create Bootstrap Accordion in a CellIt turns out, it's quite easy to do. I associated a render function with the column (see the columns.render property). When the function is called I do something similar to this: function(data, type, row, meta) { var cusip = row["CUSIP"]; var generatedNodeText = "<a data-toggle='collapse' data-target='#" + cusip + "'>" + data.length + " Documents</a>"; generatedNodeText += "<div id='" + cusip + "' class='collapse'>"; // Generate the anchors in the accordion. // You will generate whatever content is specific to your situation. for (var i in data) { // iterate over the objects in the XBRL array generatedNodeText += "<a href='" + data[i].URL + "'>" + data[i].Text + "</a><br />"; } generatedNodeText += "</div>"; return generatedNodeText; }
- 8th Jun 2016How to create a Datatable that is 100% the height of its container?Fantastic ... thank you Allan.
- 16th May 2016Create and deleting multiple dataTable tablesis there a way to destroy/empty all of the old tables with a wildcard? You can use jQuery selectors to select multiple tables (just comma separate them, like you do in CSS). Or use the $.fn.dataTable.tables() method to get the existing DataTables in a single API instance. Allan
- 29th Apr 2016Create Hyperlink column to trigger AJAX load with new URL parameterAdding the following columnDef and defining a function to recreate the table with a new data property for the ajax option worked. "columnDefs": [{ "targets": [4], "mData": null, "mRender": function(data, type, full) { return '<a href="" onclick="event.preventDefault(); searchSponsor(' + data[15] + ');">' + data[6] + '</a>'; }]
- 10th Nov 2015How do I create child row in datatable when getting data from SharePoint REST API call?Sorry msb72, I can't help you but I'm just at the stage of seeing if it is possible to bring in data into my personal GoDaddy page from my O365 site. Were you able to perform this with a REST call? Tx
- 30th Oct 2015How to use Restful API when the datatable expects more data than was sent in with the create?Good to hear you got it working! Allan
- 21st Oct 2015How to create custom filter buttonsWhat you would probably need to do is send some extra information to the server to tell it that it should ignore a specific condition - the ajax.url() method for example could be used to set a GET parameter on the URL. The PHP script would then check for that if ( ! isset( $_GET['...'] ) ) { $editor->where( ... ); } etc. Allan
- 6th Oct 2015If WP custom field contains a value create a hyperlinked entry, else make it plain text.ThomD, thanks very much for the suggestions. Looking back. I think my question wasn't clear enough. I have a JSON file, which is supplying the tabular data via an AJAX request. The variable I'd like to compare is a WordPress PHP variable ('food-status') that is not present in my JSON file. I'd consider manually adding them, but its a list that has 18,000+ entries, and I don't know a good way to automate it. If I tried to call a function from within the DataTables script, wouldn't my PHP var be outside the DataTable's scope?
- 8th Sep 2015How can I create a link using the data source in Datatables Row Grouping?Hello everyone, In case someone else encounters this problem here is the solution that someone managed to come up with: api.rows({page:'current'} ).data().each( function ( data, i ) { var group = data[0]; var groupLink = '<a href="' + data[3] + '">' + $('<div>').text(group).html() + '</a>'; if ( last !== group ) { $(rows).eq( i ).before( '<tr class="group"><td colspan="5">'+group+'</td></tr>' ); last = group; } }); And the link: https://stackoverflow.com/questions/32445714/how-can-i-create-a-link-using-the-data-source-in-datatables-row-grouping