0

How to get date and time from a source like google to html, i a order to make time browser and user computer independet

I WANT TO RUN A JAVASCRIPT AT SPECIFIC TIME, BUT I WANT TO GET DATE AND TIME FROM TRUSTED SORCE LIKE GOOGLE. AND NOT FROM USER BROWSER, IS ANY POSSIBILITY...

27th Jun 2017, 11:09 AM
ASHISH PANDEY
ASHISH PANDEY - avatar
4 odpowiedzi
+ 4
u need a timezone api like this one https://cheeze.club/p0py seems like its free tbh u can try it out
27th Jun 2017, 11:26 AM
David Sebastian Keshvi Illiakis
David Sebastian Keshvi Illiakis - avatar
+ 1
just for understanding, if want to run JavaScript for greeting - good morning, but if users browser time is not set properly, js will greeting will not be run specificly for that time if day, in order if users browser have different from real time so I just want my script to run correctly.
27th Jun 2017, 11:23 AM
ASHISH PANDEY
ASHISH PANDEY - avatar
0
I'm not exactly sure what you're asking, why would it be a problem to get the time from the user? I'd say: just take the UTC time, that'll make it even for all timezones over the world. Check this out for all date and time possibilities: https://www.w3schools.com/jsref/jsref_obj_date.asp
27th Jun 2017, 11:17 AM
Maart
Maart - avatar
0
OK thanks, i'll
27th Jun 2017, 11:31 AM
ASHISH PANDEY
ASHISH PANDEY - avatar