Search
43567 results 7351-7360
Forum
- 29th Jun 2010search data inside data table after click buttonhi all.. i have 3 textfield and 1 show button..i want after i have been type some string inside that then click the button..rhe datatable can show what i'm looking for...this is my first code: "[code] $(document).ready(function() { var oTable; $("#showdata").click(function(event){ oTable = $("#datalist").dataTable({ "bRetrieve" : true, "bServerSide": true, "bProcessing": true, "sAjaxSource": 'showlist.php', "fnServerData": function (sSource,aoData,fnCallback){ aoData.push({"name":"line","value":$("#showline").val()}); aoData.push({"name":"model","value":$("#showmodel").val()}); aoData.push({"name":"NIK","value":$("#showNIK").val()}); $.ajax({ "dataType":'json', "type":'POST', "url":sSource, "data":aoData, "success":function(json){ fnCallback(json); } }); }, "aaSorting" : [[1,"desc"]], "aoColumns" : [ /*Line*/ null, /*Model*/ null, /*NIK*/ null ] }); [/code]"
- 29th Jun 2010Initialising table with sAjaxSource errorHi, Have successfully used datatables but have found a problem when the page is re-loaded whilst the initial load is still in progress with Google Chrome or Firefox. It is fine with IE. Basically, if the page is interrupted, the error is: DataTables warning: JSON Data from the server failed to load or be parsed. This is most likely to be caused by a JSON formatting error. [code] oTable = $('#example').dataTable({ "bSortClasses": false, "sPaginationType": "full_numbers", "bAutoWidth": false, "bProcessing": true, "sAjaxSource": "/Home/DataTables", "iDisplayLength": 20, "aaSorting": [[3, "desc"]], "aoColumns": [ null, null, null, null, null, null, null ] }); [/code] I suspect is need to switch from sAjaxSource to GetJSON() but not clear how to implement it. Can you help please? Thanks, M
- 26th Apr 2010Only see the table! no functionsOn my website i wanne use Jquery plugin Datatables, On my WAMP server it works fine! But on the website with a CMS it doenst work, The only difference is that the CMS first load this page [code] <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>blabla</title> <link href="/CSS/lay-out.css" rel="stylesheet" type="text/css" /> <style type="text/css" title="currentStyle"> @import "/../../template/standaard/css/jquery-ui-1.8.custom.css"; </style> <script language="javascript" src="js/calendar.js"></script> <script type="text/javascript" src="js/jquery-latest.js"></script> <script type="text/javascript" src="js/jquery.dataTables.js"></script> <script type="text/javascript" src="js/jquery-ui-1.8.custom.min.js"></script> <!-- InstanceBeginEditable name="head" --> </head> <body bgcolor="#cacaca"> <center><table width="860" class="layout" cellpadding="7" cellspacing="0" border="0"> <tr> <td colspan="2"> <center><img src="" width="860" alt="" /></center> </td> </tr> <tr> <td class="menu" > <?php echo $this->menu(); ?> </td> <td class="content"> <?php echo $this->show_content(); ?> </td> </tr> </table></center> </body> </html> [/code] Then then it loads the page in the content (Show_content) [code] <table id="user"> <thead> <tr> <th>Rendering engine</th> <th>Browser</th> <th>Platform(s)</th> <th>Engine version</th> <th>CSS grade</th> </tr> </thead> <tbody> <tr> <td>Trident</td> <td>Internet Explorer 4.0</td> <td>Win 95+</td> <td class="center">4</td> <td class="center">X</td> </tr> </tbody> <tfoot> <tr> <th>Rendering engine</th> <th>Browser</th> <th>Platform(s)</th> <th>Engine version</th> <th>CSS grade</th> </tr> </tfoot> </table> <script>$(document).ready(function() { oTable = $('#user').dataTable({ "bJQueryUI": true, "sPaginationType": "full_numbers" }); } );</script> [/code] I just dont get it i have tried so much! Can somebody help?
- 4th Apr 2010How to best achieve custom rendering for a table columnFirst off, got to say that datables looks awesome. Now onto my issue, I have a datatable with ajax datasource (not server side processing). One of my columns is a list of colors (i.e. #232132), so what I wanted to know is how to best achieve this: I want the cell background with a particular color to be of that color, so if the cell content comes with #ff0000 I want the background for that cell to be of #ff0000, since I am quite new with datatables I wanted to know how to achieve this effect having the datasource returning only a json array of the values Thanks.
- 19th Mar 2010State Save, Server Side Ajax Tables, and Table Tools - Cookie problem.Has anyone else using this configuration come across a problem where you goto the print page, then hit the escape button to go back, and error is caused where you lose pagination. If you delete the cookie used to store the state save information, then it will be fixed temporarily, until you try and do that same set of steps again. Here is the actually Cookie itself. [code] {"iStart": 150,"iEnd": 75,"iLength": -1,"sFilter": "","sFilterEsc": true,"aaSorting": [ [0,'asc']],"aaSearchCols": [ ['',true],['',true],['',true],['',true],['',true],['',true],['',true],['',true],['',true],['',true],['',true],['',true]],"abVisCols": [ true,true,true,true,true,true,true,true,true,true,true,true]} [/code] Could the problem possibly be iLength = -1?
- 13th Mar 2010Multiple table w/ addrow and deleterow functionsSorry if repost.... I couldn't get this... It took me a whole day but nothing works... read some of the post on this forum still I can't do it... I do think Im a slow learner... Please HELP me Sample table(both table1 and table2) should look something like: Name ImANoob moveToTable1 I think the algorithm is like this.. [code] var oTable;; $(document).ready(function() { oTable = $('.dataTable').dataTable(); } ); /* Add a click handler for the delete row */ $('#moveToTable2').click( function() { oTable.dataTableExt.iApiIndex=0; var nTr = oTable.fnGetData(this); oTable.fnDeleteRow( nTr ); oTable.dataTableExt.iApiIndex=1; oTable.fnAddRow( nTr ); } ); [/code]
- 30th Apr 2025Editor PHPwill delete the link table to the file when
- 30th Apr 2025Joining tables.were in the items table, as well as web--and
- 26th Apr 2025How do you pass a customer's id to a datatable editor form?I have a users table and form and in
- 30th Apr 2025Ajax Call - Order Column/ Direction in POST Missing in v2.2.2 (was working in v1.13.4)ordering applied to the table, so it correctly doesn't