Monday, March 19, 2012

jQuery timeline plugin configuration

There are several configuration parameters that you can use for jQuery timeline plugin.

For apply the plugin you should write the next code:

$(document).ready(function () {

Where the settings is a set of key/value pairs that configure the plugin. All settings instead of timelineDataUrl are optional.

The string containing the URL to which the ajax request will be sent. The plugin expects to receive a json object (with the data about events) as a response from this URL.

Default: 'dd.MM.yyyy HH:mm'
The format string that determines how the plugin will show the dates for the events.

Default: 'en'
The language that will be used to show the months names. The plugin supports 'en' (English), 'ko' (Korean), 'ru' (Russian) by default, and can be extended to support any language.

Default: false
The value determines will the plugin show the legend block or not.

Default: 'Legend'
The string that will be shown as header for the legend block.

Default: 'Time is occupied'
The string that will be shown as a description for the event item in the legend block.

Default: function (event) { return + '<br/>' + event.startDate + ' - ' + event.finishDate; }
The function that will be used to get the html code that will be shown in the event tooltip.

1 comment:

  1. Thank you so much for the timeline plugin. Do you have any demo for this plugin?