使用 cakephp 设置自动时间输入的时间范围
我正在为一家餐厅创建预订表格。除了一个细节之外,一切都悬而未决:我想将时间输入的时间范围限制为商店的营业时间,但我在谷歌或此处找不到任何内容。假设我想将时间限制在下午 5 点至晚上 11 点。怎么办?
这就是我到目前为止所得到的。首先输入时间。
<div id="secondLine">
We'll be there at <?php echo $form->input('bookingTime', array('selected' => '19:30:00', 'interval' => '15', )); ?> on the <?php echo $form->input('bookingDate', array('dateFormat' => 'DMY', 'separator' => '', 'minYear' => '2011')); ?>
</div>
谢谢!
〜哈雷
I'm creating a booking form for a restaurant. It's all sussed except for one detail: I want to limit the time range of the time inputs to the opening hours of the store, yet I haven't been able to find anything on google or here. Say I want to limit it from 5pm-11pm. How do?
This is what I've got so far. The time input is first.
<div id="secondLine">
We'll be there at <?php echo $form->input('bookingTime', array('selected' => '19:30:00', 'interval' => '15', )); ?> on the <?php echo $form->input('bookingDate', array('dateFormat' => 'DMY', 'separator' => '', 'minYear' => '2011')); ?>
</div>
Thanks!
~Harley
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论