A way to have the local time data


#1

Hi guys, is there I way to get the local system data in android using javascript? I need to manage the “data time” of the creation of a post


#2

I have figured it out, I have used the “new Date()” object


#3

how can u give code snippet.

var date = new Date();
var d = date.now();

is this right???


#4

You can do Date.now() or

var date = new Date();
var d = date.getTime();

If you are a beginner I would highly recommend you to go through the basics of JavaScript first, may be W3Schools / Mozilla.