August 1999
Intermediate to advanced
1488 pages
72h 53m
English
date.toUTCString()The toUTCString() method returns a string representing the universal time of the Date object. The date is converted to the GMT time zone before being converted to a string. This method is exactly the same as the toGMTString().
The code in Listing 6.112 creates a Date object and initializes it to the current date and time. The toUTCString() method is then used to display the current date and time as a string in universal time.
<html> <script language="JavaScript"> <!–– Hide //Create a Date object. theDate = new Date(); //Display ... |
Read now
Unlock full access