Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript mysql datetime

var sqlDatetime = new Date(new Date().getTime() - new Date().getTimezoneOffset() * 60 * 1000).toJSON().slice(0, 19).replace('T', ' ');
console.log(sqlDatetime);
 
PREVIOUS NEXT
Tagged: #javascript #mysql #datetime
ADD COMMENT
Topic
Name
6+8 =