Quantcast
Viewing all articles
Browse latest Browse all 82115

How to use the CDN Datatables with the cdn Table tools? Setting sSwfPath?

I have been trying to get this to work. Currently, I am getting the datatables JS from the MS Ajax CDN and also getting the table tools from http://datatables.net/download/build/TableTools.min.js . When I try to use the Table Tools to get the Export to Excel and Print buttons (or any buttons), they do not render at all. All I get is a string of text at the top of the page. This leads me to think that there is an issue with the sSwfPath.

Here is my script tags:
<script type="text/javascript" charset="utf8" src="http://ajax.aspnetcdn.com/ajax/jquery.dataTables/1.9.4/jquery.dataTables.min.js"></script>
<script type="text/javascript" charset="utf8" src="http://datatables.net/download/build/TableTools.min.js"></script>

Here is the datatables initialization:

 var oTable = $('#detailed_data').dataTable( {
                        "iDisplayLength": 20,
                        "sSearch": "Search all columns:",
                        "sPaginationType": "full_numbers",
                        "bFilter": false,
                        "sScrollXInner": "110%",
                        "sDom": 'T<"clear">lfrtip',
                        "oTableTools": {
                            "sSwfPath": "http://datatables.net/download/build/TableTools.min.js/media/swf/copy_csv_xls_pdf.swf"
                        }
                });
(FYI: this is also being plugged into a JQuery Dialog to be displayed as a "popup").
With this last configuration, the menu option at the top is NOT displaying and the page row limit does not work (shows all rows).
This site is an internal corporate site so I cannot supply a link. I will try to get some data into a fiddle soon if necessary.
Any help is appreciated.

Viewing all articles
Browse latest Browse all 82115

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>