Since: SearchPanes 1.4.0

Set the message to be displayed in the Collapse button.
Please note - this property requires the SearchPanes extension for DataTables.


SearchPanes will set the message to be displayed in the Collapse button to 'Collapse All'. This property allows that message to be configured. It is a global setting that will impact all instances of SearchPanes on a DataTable (it should be noted that it is uncommon to have more than one instance!). The per-instance parameter is searchPanes.i18n.collapseMessage, which also defines the default.

This option is useful as the language object can be loaded by Ajax, or set locally and define all language strings used by DataTables and its extensions.




Setting the searchPanes.i18n.collapseMessage option to a string of your choice allows the Collapse All button to have custom text within it.

This property is passed through an i18n() function.


Change message for the Collapse button:

new DataTable('#myTable', {
	language: {
		searchPanes: {
			collapseMessage: 'Hide SearchPanes'
	layout: {
		top1: 'searchPanes'