Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get local date-time and not server date-time

I am making a Java web application in whcih customers in different countries are required to upload file through a jsp page.I have to deploy this application in Weblogic server.

Now what i want is their local date-time.I dont want server date-time.

What code should I write in my java application to get their local date and time.

like image 375
Sankalp Avatar asked Feb 18 '23 22:02

Sankalp


1 Answers

It's tough to get time of user/client unless you pass it explicitly in the post/Ajax call.

Capture time in Javascript and then send it to server in http request.

URL : http://www.w3schools.com/jsref/jsref_obj_date.asp

like image 74
rai.skumar Avatar answered Feb 20 '23 10:02

rai.skumar