{hero}

error()

Since: DataTables 2.0

Trigger an error message.

Description

This method is used to show error messages to the developer building on DataTables (or to the end user if the error occurs in a deployed environment). It is primarily intended for use by plug-in developers who need to report an error state in the same way as DataTables core does (i.e. the DataTable.ext.errMode parameter will determine how the error message is shown).

Type

function error( msg )

Description:

Show an error message to the end user / developer.

Parameters:
Returns:

API instance for chaining.

Example

Simple call of the method:

var table = new DataTable('#myTable');

table.error('Plug-in configuration error message...');