[jQuery] Re: Date and Time

2008-09-04 Thread Michael Geary

jQuery doesn't have any functions to deal with date and time. You can use
standard JavaScript functions for this. Some examples:

// Get the current date/time as a Date object
var date = new Date;

// Get the numeric representation of the date/time in UTC
// (number of milliseconds since midnight UTC 1/1/1970)
var utcTime = date.getTime();

// Get the user's time zone offset in minutes
var tzOffset = date.getTimezoneOffset);

For more information, search for:

javascript date

-Mike

> Is it possible to get the Date and Time of a user and convert 
> it to UTC using JQuery?
> 
> I need to find the time zone of the user to display the 
> server time in that time zone and when the user inserts a 
> date and time convert it back to UTC to place it in the database.
> 
> Thanks,
> Miguel



[jQuery] Re: Date and Time

2008-09-04 Thread MorningZ

Why not just use plain ol javascript?

http://www.google.com/search?q=javascript+convert+to+UTC

(which ultimately a jQuery plugin would do anyways)