Table Tools - turning on/off

Table Tools - turning on/off

akreiderakreider Posts: 33Questions: 0Answers: 0
edited February 2010 in TableTools
I'm using Table Tools. I want the export functions/buttons to be on for some tables, and off for other tables. Currently they are all on.

Either the functionality needs to be off, or simply hiding the four buttons would suffice.

Replies

  • allanallan Posts: 61,438Questions: 1Answers: 10,051 Site admin
    Hi akreider,

    If you don't want TableTools in a table, then just don't include it in the sDom specification for that table. To change the features of a specific table tools instance, you can change the properties in 'TableToolsInit' before the DataTable is initialised. The features in TableTools are controlled by:

    [code]
    TableToolsInit = {
    "oFeatures": {
    "bCsv": true,
    "bXls": true,
    "bCopy": true,
    "bPrint": true
    }
    ...
    }
    [/code]
    Regards,
    Allan
  • akreiderakreider Posts: 33Questions: 0Answers: 0
    It looks like sDom has 'T<"clear">' in it, and getting rid of that removes the TableTools.

    "sDom": 'T<"clear">lfrtip' - has Table Tools
    "sDom": 'lfrtip' - does not have Table Tools
  • allanallan Posts: 61,438Questions: 1Answers: 10,051 Site admin
    Yup - the 'T' is the indicator for where TableTools is setup. the <"clear"> adds a div with class 'clear'.

    Allan
This discussion has been closed.