Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting the date from the server?

Status
Not open for further replies.

caffeinerusher

Programmer
Mar 7, 2001
31
US
Hi all,

Is it possible to access the date/time on the server using javascript. I can get the date/time of the machine, but I need something a bit more reliable. Any Ideas?

--Caffeinerusher
 
In an .asp you can in server side...

var TodayMonth = Today.getMonth() + 1;
var TodayDay = Today.getDate();
var TodayYear = Today.getFullYear();
var DisplayToday = TodayMonth + "/" + TodayDay + "/" + TodayYear;
I started out with nothing, and I still have most of it.
 
I could do it with a JSP, but currently that pages I need to work with are not jsp. That is why I am looking for a javascript solution, if there is one. Thank you for the response.

--Caffeinerusher
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top