Author: Jan de Mooij License: GNU GENERAL PUBLIC LICENSE Version 2, June 1991 (see LICENSE file)
jQuery UI widget for dragging over a table to select (multiple) timeranges. The widget is tied to an html div. Once the widget is initialized, it generates a table with a row for each hour and a cell for each minute interval within that hour. The user can select multiple timeranges in the table, usually for one single day.
This widget requires jQuery (version 1.11 or up) and moment.js
Make sure you load jQuery first and then moment.js Only after that should you load the widget.
HTML:
<html>
<head>
<!-- Load JQuery -->
<!-- Load moments.js -->
<link type="text/css" rel="stylesheet" href="timerange-selector-ui/timerangeselector.css"/>
<script src="timerange-selector-ui-/jquery.ui.timerangeselector.js"></script>
</head>
<body>
<div id="time-selector"></div>
<script>
$("time-selector").selectorTable();
</script>
</body>
</html>
Options | Methods |
---|---|
Resolution | destroy() |
tableClass | getTimes() |
hourStart | reset() |
hourEnd | |
hourText | |
selected | |
hourFormat24 |