Javascript Date toDateInputValue =(function()

Description

Javascript Date toDateInputValue =(function()


Date.prototype.toDateInputValue = (function() {
    var local = new Date(this);
    local.setMinutes(this.getMinutes() - this.getTimezoneOffset());
    return local.toJSON().slice(0,10);
});//from  w w w  .  ja  v a  2 s .  c o m



PreviousNext

Related