Date.toGMTString() (Method)

Converts a Date object to a string containing a GMT time.

Availability:

ECMAScript edition - 2
JavaScript - 1.0
JScript - 1.0
Internet Explorer - 3.02
Netscape - 2.0
Netscape Enterprise Server - 2.0
Opera - 3.0
Deprecated in JavaScript 1.3
Property/method value type:String primitive
JavaScript syntax:-myDate.toGMTString()

This method returns a string value containing a GMT representation of the date and time value in the receiving object. The contents of the string are implementation-dependent, but are intended to represent the date in a convenient, human-readable form. However, this method is now deprecated in favor of Date.toUTCString() which should be used in preference. It is provided merely for compatibility with older systems.

As of ECMA edition 3 it is no longer included in the standard although implementations may still provide it for backwards compatability.

Warnings:

See also:Cast operator, Cookie expires, Date.prototype, Date.toUTCString()

Cross-references:

ECMA 262 edition 2 - section - 15.9.5.41

ECMA 262 edition 3 - section - B.2.6