{hero}

language.searchPanes

Since: SearchPanes 1.0.0

Container for options for language.
Please note - this property requires the SearchPanes extension for DataTables.

Description

This parameter is an object that can be used to customise the language strings used by SearchPanes.

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!). Per-instance parameters are found under the searchPanes.i18n object's parameters which also defines the default values.

This top level 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.

Type

string

Description:

This option is capable of holding all of the sub-options for languages for the panes.

Examples

Alter title messages: :

new DataTable('#myTable', {
	layout: {
		top1: 'searchPanes'
	},
	language: {
		searchPanes: {
			title: {
				_: 'Filters Selected - %d',
				0: 'No Filters Selected',
				1: 'One Filter Selected'
			}
		}
	}
});

Change messages for viewTotal::

new DataTable('#myTable', {
	layout: {
		top1: {
			searchPanes: {
				viewTotal: true
			}
		}
	},
	language: {
		searchPanes: {
			count: '{total} found',
			countFiltered: '{shown} ({total})'
		}
	}
});

Related

The following options are directly related and may also be useful in your application development.