微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

timer.jquery

编程之家收集整理的这个编程导航主要介绍了timer.jquery编程之家,现在分享给大家,也给大家做个参考。

timer.jquery 介绍

jQuery Timer:在任何html元素内启动/停止/恢复/删除漂亮的计时器。  特点

轻量级,经过良好测试的jQuery 漂亮计时器插件

在任何html元素内启动,暂停,恢复和删除计时器。

在特定时间后或定期获取通知

在计时器运行时单击并编辑时间!

在同一页面上启用多个计时器

用法

$("#div-id").timer(options);

要使用选项启动计时器:

$("#div-id").timer({

seconds: {Int},// The number of seconds to start the timer from

duration: {String},// The time to countdown from. `seconds` and `duration` are mutually exclusive

callback: {Function},// If duration is set,this function is called after `duration` has elapsed

repeat: {Bool},`callback` will be called repeatedly

format: {String},// Format to show time in

editable: {Bool} // If click and edit time is enabled

hidden; {Bool} // If true,the timer is not displayed in the selected item.

});

初始化计时器上可用的方法

//pause an existing timer

$("#div-id").timer('pause');

//resume a paused timer

$("#div-id").timer('resume');

//remove an existing timer

$("#div-id").timer('remove'); //leaves the display intact

//get elapsed time in seconds

$("#div-id").data('seconds');

 

网站地址:https://jquerytimer.com

GitHub:https://github.com/walmik/timer.jquery

网站描述:jQuery计时器插件

timer.jquery

官方网站:https://jquerytimer.com

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。