I have datetime-local html control on my form and I need to set date and time on it dynamically via JS or jQuery. How can I do it?
What about?
var now=new Date(); console.log(new Date(now.getTime()-now.getTimezoneOffset()*60000).toISOString().substring(0,19));