//23.12.2015 08:34:50
var a = new Date().toString ();
var parts = a.split(" ");
var mon = ["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];
for (var i = 0; i < 12; i++){
parts[1] = parts[1].replace(mon[i],i + 1);
}
parts[1] = parts[1].padStart(2,"0");
var TS = parts[2] + "." + parts[1] + "." + parts[3] + " " + parts[4];
Code Example |
---|
:: Copy an Array with the Spread Operator |
:: |
:: |
Javascript :: a7aad |
Javascript :: |
Javascript :: sintaxis map javascript |
Javascript :: |
Javascript :: |
:: |
:: |
Javascript :: returns string of names, seperated by commas and an ampersand namesObj in javascript |
Javascript :: |
:: submit file js |
Javascript :: |
:: |
Javascript :: |
:: |
:: binary function |
:: |
:: Alternative Syntax For Backbone Simple Template |
Javascript :: |
:: |
Javascript :: Backbone.model first parameter determines properties that each instance must have |
:: |
Javascript :: |
:: |
Javascript :: |
:: |
:: |
Javascript :: |