当前位置:网站首页>JS countdown case
JS countdown case
2022-07-02 06:52:00 【Overnight ξ】
// Countdown cases
function conutDown(time) {
var nowTime = +new Date() // Returns the total number of milliseconds of the current time
var inputTime = +new Date(time) // Returns the total number of milliseconds of user input time
var Times = (inputTime - nowTime) / 1000 // Total milliseconds remaining
var d = parseInt(Times / 60 / 60 / 24)
d = d < 10 ? '0' + d : d
var h = parseInt(Times / 60 / 60 % 24)
var m = parseInt(Times / 60 % 60)
var s = parseInt(Times % 60)
return d + ' God ' + h + ' when ' + m + ' branch ' + s + ' second '
}
console.log(conutDown('2022-2-14 15:00:00'))边栏推荐
- In depth study of JVM bottom layer (V): class loading mechanism
- Record RDS troubleshooting once -- RDS capacity increases dramatically
- Eslint configuration code auto format
- sprintf_s的使用方法
- CVE-2015-1635(MS15-034 )遠程代碼執行漏洞複現
- [literature reading and thought notes 13] unprocessing images for learned raw denoising
- Vector types and variables built in CUDA
- Common prototype methods of JS array
- Latex warning: citation "*****" on page y undefined on input line*
- [self cultivation of programmers] - Reflection on job hunting Part II
猜你喜欢

Sqli labs customs clearance summary-page3

Utilisation de la carte et de foreach dans JS

Latex 编译报错 I found no \bibstyle & \bibdata & \citation command

Latex compilation error I found no \bibstyle &\bibdata &\citation command

Pytest (1) case collection rules

No process runs when querying GPU, but the video memory is occupied

SQL注入闭合判断

Fe - wechat applet - Bluetooth ble development research and use

Thread hierarchy in CUDA

ZZQ的博客目录--更新于20210601
随机推荐
Self study table Au
Selenium+msedgedriver+edge browser installation driver pit
apt命令报证书错误 Certificate verification failed: The certificate is NOT trusted
20201025 visual studio2019 qt5.14 use of signal and slot functions
The table component specifies the concatenation parallel method
Win10网络图标消失,网络图标变成灰色,打开网络设置闪退等问题解决
Date time API details
Render minecraft scenes into real scenes using NVIDIA GPU
Virtualenv and pipenv installation
浏览器滚动加载更多实现
[self cultivation of programmers] - Reflection on job hunting Part II
[Zhang San learns C language] - deeply understand data storage
【文献阅读与想法笔记13】 Unprocessing Images for Learned Raw Denoising
SQL注入闭合判断
Huawei mindspire open source internship machine test questions
Cve - 2015 - 1635 (ms15 - 034) réplication de la vulnérabilité d'exécution de code à distance
2020-9-23 use of QT timer qtimer class.
Automation - when Jenkins pipline executes the nodejs command, it prompts node: command not found
js把一个数组分割成每三个一组
flex九宫格布局