我在哪里可以找到Javascript / jQuery中的时间范围小部件? [英] Where can I find a time range widget in Javascript/jQuery?
问题描述
我正在寻找Javascript / CSS / jQuery中的某种TimeRange小部件。我不是在寻找广泛使用的时间/日期选择器。
I'm looking for some sort of TimeRange widget in Javascript/CSS/jQuery. I'm not looking for a time/date picker, which are widely available.
我需要一个网站,允许企业通过点击和悬停选择他们的开放时间他们打开的时间。
I need it for a website to allow businesses to select their openinghours by clicking and hovering over the hours they're open.
+-----------------------------+
| 0h 0h15m 0h30m ... 23:45 |
+-----------------------------+
有人看过这么好看的可定制时间范围选择器小部件吗?
Anybody has seen such a nice looking customizable timerange selector widget?
干杯
推荐答案
我会寻找一个滑块小工具..然后设置你需要的时间间隔。
I'd look for a slider widget.. then set the times you need as the intervals.
jQuery UI有一个: jQuery UI Slider 。
The jQuery UI has one: jQuery UI Slider.
更新:根据以下评论(单一与双滑块)...
Update: based on the comment below about (single vs. double slider)...
1。)已经(刚刚找到)关于使用jQuery UI滑块制作 2处理滑块的帖子。
1.) Theres a post already (just found) about making a 2 handled slider using the jQuery UI slider here.
或者如果您有2个滑块...一个用于打开时间,一个用于关闭...其中每个滑块分为15分钟段,但每个只有半天,这会有用吗?
Or if you have 2 sliders... one for opening time and one for closing... where each is broken down into 15min segments, but only for half a day each, would this work?
例如(忽略ASCII图形丑陋)
e.g. (ignore the ASCII-graphic uglyness)
Open Time (AM): 12 1 2 3 4 5 6 7 8 | 9 10 11 12
^ 8:15am
Close Time (PM): 12 1 2 3 4 5 6 | 7 8 9 10 11 12
^6:30pm
此外,如果是典型的商家......你可能会从下午11点开始chop - 从凌晨5点开始。
Furthermore, if this is for "typical" businesses... you could likely chop from 11pm <-> 5am from the sliders.
或者,
我不喜欢scriptaculous,但他们似乎有一个双滑块:
I'm not a big fan of scriptaculous, but they seem to have a double slider:
这篇关于我在哪里可以找到Javascript / jQuery中的时间范围小部件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!