当前位置:网站首页>Digital type processing and convenient method of ext JS
Digital type processing and convenient method of ext JS
2022-07-19 03:36:00 【oscar999】
JavaScript Of Date type
Creation of time object
How to create date objects :
myDate = new Date();
myDate = new Date("December 19, 1983 03:24:00");
myDate = new Date(1983,11,19);
myDate = new Date(1983,11,17,3,24,0);
- Without parameters, you create a current date
- You can use the local time substring as a parameter ; You can also pass in year, month, and day as parameters ; You can also import the date , Hours, minutes and seconds as parameters .
Date
- Time can be converted into a number in milliseconds , The conversion is based on international standard time (UTC) Of 1970 year 1 month 1 Midnight on the th is the starting point . The number of milliseconds in a day is 246060*1000 = 86,400,000.
- Date Type of date has a time range , With 1970 year 1 month 1 Day as the center point , Forward and backward 100,000,000 God .
- Date Type of date supports multiple time formats , such as UTC,GMT etc.
How to get the number of milliseconds of time :
The way 1: Use static methods of classes : Date.now();
//2. Get the number of milliseconds of time
var dateMilSecs = Date.now();
console.log(dateMilSecs);
The way 2: Using the getTime() Method
var date = new Date();
dateMilSecs = date.getTi边栏推荐
猜你喜欢

Solve the error of 0x00000709 when win10 connects to the shared printer

Yolov5 ncnn reasoning

By voting for the destruction of STI by Dao, seektiger is truly community driven

Wdog and power mode of fs32k148 commissioning

神经网络学习笔记2.2 ——用Matlab写一个简单的卷积神将网络图像分类器

laravel的问题

367. 有效的完全平方数(入门必会)

leetcode162. Looking for peak

Transaction and storage engine in MySQL database
![2022-07-16: what is the output of the following go language code? A:[]; B:[5]; C:[5 0 0 0 0]; D:[0 0 0 0 0]。 package main import ( “fmt“ )](/img/e4/ff7f1e19583f42377307de7291f870.png)
2022-07-16: what is the output of the following go language code? A:[]; B:[5]; C:[5 0 0 0 0]; D:[0 0 0 0 0]。 package main import ( “fmt“ )
随机推荐
Note: light source selection and Application
Unity解决同材质物体重叠产生Z-Fighting的问题
Win10 network connection shows no network but Internet access
上班摸鱼打卡模拟器微信小程序源码
module_ Basic principle of init function
MySQL 增删查改(基础)
Replacement operation not supported by ncnn partial operators
谷歌 Chrome 浏览器安装 PWA 应用将显示更多描述信息
Leetcode: 0-1 knapsack problem in dynamic programming [come and set the template directly]
How to read and write a single document based on MFC
Chengxin University envi_ IDL second week class content: open hdf4 file and read the file, as well as simple data processing and saving + detailed analysis
leetcode:78. subset
KubeCon + CloudNativeCon Europe 2022
Dqn theoretical basis and code implementation [pytoch + cartpole-v0]
Transaction and storage engine in MySQL database
RuntimeError_ Input type (torch.FloatTensor) and weight type (torch.cuda.FloatTensor)
Configure high availability using virtual ip+kept
Flutter development: running the flutter upgrade command reports an error exception:flutter failed to create a directory at... Solution
Laravel's problem
Face key point detection