时间啄木鸟使用jquery的时间差异 [英] Difference hours between time pecker using jquery

查看:74
本文介绍了时间啄木鸟使用jquery的时间差异的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

时间啄木鸟和时间啄木鸟之间的差异时间包含值看起来像10:45 AM而另一个是晚上7:30使用jquery

Difference hours between time pecker and the time peckers are contains the value look like 10:45AM and another one is 7:30PM using jquery

推荐答案

。你可以使用由函数< code> Date< / code>创建的日期对象(实际上表示时间刻度上的点,而不是日期)定义的运算符' - '。例如:

.You can use the operator '-' defined for the date objects (representing actually the point on a time scale, not "date") created by the function <code>Date</code>. For example:
first = new Date(2013, 1, 1, 1, 1, 1, 1);
second = new Date(2014, 2, 1, 1, 1, 1, 100);
duration = second - first;

有关详细信息,请参阅: http:// www.w3schools.com/jsref/jsref_obj_date.asp [ ^ ]。



-SA

For further information, please see: http://www.w3schools.com/jsref/jsref_obj_date.asp[^].

—SA


这篇关于时间啄木鸟使用jquery的时间差异的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆