DateTime

DateTime is a slightly unusual extension for DataTables, in that it doesn't add anything to the table itself, but rather provides a common utility library for other extensions to make use of. Through this method we have a common date / time UI picker throughout the DataTables suite, wherever such a component is useful. It can also be used externally to DataTables, so you can use the same UI throughout all components on your site.

As well as standard JS Date formats, DateTime provides full integration with Moment, Luxon and Dayjs.

Features

DateTime provides the following features:

  • Easy Date and Time selection
  • Fully customisable date formats
  • Fully customisable locale
  • Fully internationalisable
  • Common date / time picker for DataTables extensions
  • Can be used externally to DataTables

As with all DataTables extensions it can of course have all language strings localised and has complete documentation.

Demo

The table below is an example of how DateTime can be used.

When focus is given to the input element (i.e. click on it, or tab into it), the picker will appear, allowing the user to easily select a date / time value. The picker be customised for different formats, layouts and languages. The input can also be hidden or made readonly if you wish to require the end user to use the picker only.

Check out the full set of examples to explore more of DateTime's capabilities.

Next

Continue with DateTime by learning: